Skip to content
Open
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
4 changes: 3 additions & 1 deletion .github/workflows/build-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ jobs:
- uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
with:
node-version-file: '.nvmrc'
- name: Install uv
uses: astral-sh/setup-uv@v7

- name: Install NPM packages
run: npm ci
Expand All @@ -27,7 +29,7 @@ jobs:
npm run generate-typings

- name: Build docs
run: npm run mkdocs-build
run: npm run docs-build


- name: Deploy
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ We aim to avoid breaking changes in the MapLibre style specification because it
## Documentation

The [documentation](https://maplibre.org/maplibre-style-spec) of the style specification also lives in this repository.
We use [MkDocs](https://www.mkdocs.org/) with the [Material for MkDocs](https://squidfunk.github.io/mkdocs-material) theme.
We use [Zensical](https://www.zensical.org/).

To work on the documentation locally, you need to have Docker installed and running.
Start MkDocs with
To work on the documentation locally, you need to have [UV](https://docs.astral.sh/uv/getting-started/installation/) and [python](https://www.python.org/downloads/) installed.
Start Zensical with

```bash
npm run mkdocs
npm run docs
```

Most of the documentation is generated (from e.g. `v8.json`).
Expand Down Expand Up @@ -91,4 +91,4 @@ $ gl-style-validate style.json
```

Will validate the given style JSON and print errors to stdout.
Provide a `--json` flag to get JSON output.
Provide a `--json` flag to get JSON output.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
"generate-style-spec": "node --no-warnings --loader ts-node/esm build/generate-style-spec.ts",
"generate-typings": "dts-bundle-generator -o ./dist/index.d.ts ./src/index.ts",
"generate-docs": "node ${WATCH+--watch} --no-warnings --loader ts-node/esm build/generate-docs.ts",
"mkdocs": "docker run --rm -it -p 8000:8000 -v ${PWD}:/docs squidfunk/mkdocs-material",
"mkdocs-build": "npm run generate-docs && docker run --rm -v ${PWD}:/docs squidfunk/mkdocs-material build --strict",
"docs": "uvx zensical serve --open",
"docs-build": "npm run generate-docs && uvx zensical build",
"test": "vitest",
"test-unit": "vitest run --config vitest.config.unit.ts",
"test-unit-ci": "vitest run --config vitest.config.unit.ts --coverage",
Expand Down
Loading