Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
npx playwright install --with-deps
- name: Build the website
run: |
npm run build
npm run docs:build
- name: Check Types
run: |
npm run check:types
Expand Down
15 changes: 5 additions & 10 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,8 @@ $ nvm use

## Local Development

The local development flow is based around building the docs website, using `wcc` in an SSG based workflow, and running tests.
The local development workflows for WCC are:

### Commands

These are the main tasks, and you can see them all listed in _package.json#scripts_.

- `npm run dev` - Builds the docs site for local development
- `npm test` - Run all the tests
- `npm test:tdd` - Run all the tests in watch mode
- `npm run lint` - Run all linters
Expand All @@ -45,11 +40,11 @@ These are the main tasks, and you can see them all listed in _package.json#scrip

The website is built with [**Greenwood**](https://www.greenwoodjs.dev). To run the website locally, use one of the following commands:

- `npm run dev` - Start the dev server
- `npm run build` - Generate a production build
- `npm run serve` - Serve a production build
- `npm run docs:dev` - Start the dev server
- `npm run docs:build` - Generate a production build
- `npm run docs:serve` - Serve a production build

To run tests for the website, first make sure you have at least run `npm run build`, then:
To run tests for the website, first make sure you have at least run `npm run docs:build`, then:

- `npm run test:docs` - Run a single suite of tests with Vitest
- `npm run test:docs:tdd` - Run the test suite with Vitest in watch mode
Expand Down
2 changes: 1 addition & 1 deletion netlify.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[build]
publish = "public/"
command = "npm run build"
command = "npm run docs:build"

[build.processing]
skip_processing = true
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@
"access": "public"
},
"scripts": {
"dev": "greenwood develop",
"build": "NODE_OPTIONS='--import @greenwood/cli/register' greenwood build",
"serve": "greenwood serve",
"docs:dev": "greenwood develop",
"docs:build": "NODE_OPTIONS='--import @greenwood/cli/register' greenwood build",
"docs:serve": "greenwood serve",
"lint": "npm run lint:js && npm run lint:ls && npm run lint:css",
"lint:js": "eslint",
"lint:ls": "ls-lint",
Expand Down