Files
zui/CONTRIBUTING.md
2026-03-20 10:48:06 +01:00

51 lines
2.0 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Contribution Guide
## 1. Coding Standards
- Use TypeScript with `strict` mode enabled.
- Follow the import order: core, library, project, then relative.
- Naming: PascalCase for components, camelCase for functions/variables, UPPER_SNAKE_CASE for constants.
- Add JSDoc comments for all public APIs.
- Keep line length <= 120 characters, use Prettier for formatting.
- Lint with `pnpm lint` and fix warnings.
## 2. Branch Workflow
- Create a feature branch: `git checkout -b feat/<short-description>`
- Keep branches up to date with `main` via `git rebase` or `git merge --ff-only`.
- Submit a Pull Request with a clear title and description.
- Ensure PR passes CI (tests, lint, type-check).
- Address review comments promptly.
## 3. Running Tests
- Install dependencies: `pnpm install`.
- Run tests in watch mode: `pnpm test --watch`.
- Run tests with coverage: `pnpm test --coverage`.
- Run lint: `pnpm lint`.
- Run type-check: `pnpm typecheck`.
## 4. Making Your First Contribution
1. Pick a beginner-friendly issue labeled `good first issue`.
2. Follow the steps in the Quickstart guide.
3. Make a small change (e.g., fix typo, add JSDoc).
4. Run the relevant tests.
5. Commit and push, then open a PR.
## 5. Where to Extend (AI Agent Guidance)
- **Canvas rendering**: Extend `src/app/canvas/CanvasPage.tsx` by adding new node types or customizing the context menu.
- **Recollection management**: Modify `src/app/recollections/RecollectionsPage.tsx` to add new views or actions.
- **State management**: Update `src/app/canvas/canvasStore.ts` for new graph features.
- **Performance**: Optimize expensive renders in `src/app/recollections/RecollectionsPage.tsx` using memoization.
## 6. Useful Links
- [ARCHITECTURE.md](ARCHITECTURE.md) High-level architecture overview.
- [PERFORMANCE_IMPROVEMENTS.md](PERFORMANCE_IMPROVEMENTS.md) Performance improvement plan.
- [QUICKSTART_FOR_JUNIORS.md](QUICKSTART_FOR_JUNIORS.md) Junior developer quickstart.
- [CODE_REVIEW_CHECKLIST.md](CODE_REVIEW_CHECKLIST.md) Checklist for reviewers.
*Thank you for contributing!*