Contributing
Contributions are welcome! This page covers everything you need to get the project running locally and submit changes.
Setup
Clone the repo and install root dependencies:
sh
git clone https://github.com/juleshry/vue-animejs.git
cd vue-animejs
bun installsh
git clone https://github.com/juleshry/vue-animejs.git
cd vue-animejs
npm installsh
git clone https://github.com/juleshry/vue-animejs.git
cd vue-animejs
pnpm installsh
git clone https://github.com/juleshry/vue-animejs.git
cd vue-animejs
yarn installPlayground
The playground is a standalone Vite app for manual testing. It has its own package.json and must be installed separately:
sh
cd playground
bun install && bun run playground:devsh
cd playground
npm install && npm run playground:devsh
cd playground
pnpm install && pnpm run playground:devsh
cd playground
yarn install && yarn playground:devDocs
The documentation site (this site) is also a separate sub-project:
sh
cd docs
bun install && bun run docs:devsh
cd docs
npm install && npm run docs:devsh
cd docs
pnpm install && pnpm run docs:devsh
cd docs
yarn install && yarn docs:devTests
Unit tests live in tests/ and run with Vitest:
sh
bun run testWatch mode:
sh
bun run test:watchCoverage report:
sh
bun run test:coverageAdding a Composable
- Create
src/composables/use-my-feature.ts - Write the composable with full TypeScript types and JSDoc
- Register cleanup in
onUnmounted - Export it from
src/index.ts - Test it manually in the playground
- Add a doc page under
docs/src/composables/use-my-feature.md
See the Documentation Rules for the expected page structure.
Code Style
Formatting is handled by oxfmt and linting by oxlint. Run both before committing:
sh
bun run format
bun run lintFormat check only (used in CI):
sh
bun run format:checkKey conventions:
- 2-space indentation, double quotes, no semicolons
- Local variables use
snake_case; functions and parameters usecamelCase - Composable files: exports first, helpers below