If you find a bug in the source code or a mistake in the documentation, you can help us by submitting an issue to our GitHub repository. Even better, you can submit a pull request with a fix.
You need the current Node.js LTS (.nvmrc) and pnpm (the version in package.json's packageManager). A dev container in .devcontainer/ has everything installed.
- Clone the repository and run
pnpm install. - Run tasks through Nx, for example:
pnpm nx test chartist --watch: the library's unit tests in watch mode.pnpm --dir packages/examples exec vite line/simple: run one example.pnpm nx dev docs: the docs site at http://localhost:4321.pnpm nx run visual:test:visual: compare every example with the screenshot baseline. The committed baselines are recorded on Linux with Playwright's Chromium; on other machines, fonts render differently, so usepnpm nx run visual:test:visual:local-baselineonce and thenpnpm nx run visual:test:visual:local.
The repository layout and the standing decisions are described in docs/decisions.md; the behavior of each part is specified in openspec/specs/.
- Fork the repository and branch from
main. - Use conventional commit messages (
fix: …,feat: …,docs: …); they drive the changelog. - Keep file moves and deletions in commits of their own, so git can follow the files' history.
- Run
pnpm nx formatbefore committing, and make surepnpm nx run-many -t lint typecheck check testpasses. - Code follows the TypeScript guidelines in
docs/typescript.md: functional, immutable, named exports. - Docs pages follow
apps/docs/WRITING.md, doc commentspackages/chartist/DOC-COMMENTS.md.