Thank you for your interest in contributing! This document provides guidelines and instructions for contributing to the project.
- Fork the repository on GitHub
- Clone your fork locally
git clone https://github.com/your-username/ownchart.git cd ownchart - Install dependencies
npm install
- Create a branch for your changes
git checkout -b feature/your-feature-name
- Check existing issues and PRs to avoid duplicates
- For major changes, open an issue first to discuss
- Read the relevant documentation in
/concept
- Write code following our style guide
- Add tests for new functionality
- Update documentation if needed
- Run quality checks
npm run ci:local
TypeScript:
- Use strict mode (no
anytypes) - Explicit return types for functions
- Descriptive variable names
- Follow existing patterns
React:
- Functional components with hooks
- Named exports (not default)
- Props interface for every component
- Keep components focused and under 200 lines
Testing:
- Write tests before implementation (TDD)
- Test coverage ≥80% overall
- 100% coverage for critical modules
- Include edge cases and error scenarios
Follow the Conventional Commits specification:
<type>(<scope>): <description>
[optional body]
[optional footer]
Types:
feat- New featurefix- Bug fixdocs- Documentation onlystyle- Formatting, missing semicolons, etc.refactor- Code change that neither fixes a bug nor adds a featuretest- Adding or updating testschore- Updating build tasks, package manager configs, etc.
Examples:
feat(tasks): add drag-and-drop for task reordering
fix(dependencies): prevent circular dependency creation
docs(readme): update installation instructions
test(utils): add edge cases for date calculations
- Update documentation for any changed functionality
- Ensure all tests pass locally
npm run ci:local
- Update version in package.json if needed (maintainers will handle for releases)
- Create the PR with a clear title and description
- Link related issues using keywords (Fixes #123, Closes #456)
- Wait for review - maintainers will review within 48 hours
Use the same format as commit messages:
feat: add task filtering by assignee
fix: resolve date calculation edge case
## Description
Brief description of the changes
## Type of Change
- [ ] Bug fix
- [ ] New feature
- [ ] Breaking change
- [ ] Documentation update
## Related Issues
Fixes #(issue number)
## Testing
- [ ] Unit tests added/updated
- [ ] Integration tests added/updated
- [ ] E2E tests added/updated
- [ ] All tests passing locally
## Checklist
- [ ] Code follows style guidelines
- [ ] No hardcoded color values — use design tokens or Tailwind classes (run `npm run lint:colors`)
- [ ] Self-review completed
- [ ] Comments added for complex code
- [ ] Documentation updated
- [ ] No new warnings generated
- [ ] Tests added that prove fix/feature worksMaintain these coverage levels:
- Overall: ≥80%
- Critical modules: 100%
dependencyUtils.tsvalidationUtils.tshistoryStore.tstaskStore.ts
Unit Tests (70% of tests):
import { describe, it, expect } from 'vitest';
import { calculateDuration } from './dateUtils';
describe('calculateDuration', () => {
it('calculates duration in days correctly', () => {
const start = new Date('2025-01-01');
const end = new Date('2025-01-05');
expect(calculateDuration(start, end)).toBe(4);
});
});Integration Tests (20% of tests):
import { renderHook, act } from '@testing-library/react';
import { useTaskStore } from './taskStore';
describe('Task Store Integration', () => {
it('creates task and updates dependencies', () => {
// Test multi-component interactions
});
});E2E Tests (10% of tests):
import { test, expect } from '@playwright/test';
test('user can create and edit task', async ({ page }) => {
// Test complete user flows
});- Respond to review comments promptly
- Make requested changes in new commits (don't force push)
- Mark conversations as resolved when addressed
- Ask questions if feedback is unclear
Reviewers will check:
- Code quality and style
- Test coverage and quality
- Documentation updates
- No breaking changes (unless justified)
- Performance implications
- Security considerations
- Accessibility compliance
Use the bug report template:
**Describe the bug**
A clear description of what the bug is.
**To Reproduce**
Steps to reproduce:
1. Go to '...'
2. Click on '...'
3. See error
**Expected behavior**
What you expected to happen.
**Screenshots**
If applicable, add screenshots.
**Environment:**
- Browser: [e.g., Chrome 120]
- OS: [e.g., Windows 11]
- Version: [e.g., 1.0.0]
**Additional context**
Any other context about the problem.Use the feature request template:
**Is your feature request related to a problem?**
A clear description of the problem.
**Describe the solution you'd like**
A clear description of what you want to happen.
**Describe alternatives you've considered**
Other solutions you've thought about.
**Additional context**
Mockups, examples, or other context.- Node.js 20.x or higher
- npm 10.x or higher
- Git
- Modern browser (Chrome, Firefox, or Safari)
- VS Code with extensions:
- ESLint
- Prettier
- TypeScript and JavaScript Language Features
- Tailwind CSS IntelliSense
- Git GUI (GitKraken, SourceTree, or similar)
VS Code Settings (.vscode/settings.json):
{
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"typescript.tsdk": "node_modules/typescript/lib"
}Contributions should align with the current phase:
- Phase 0 (v0.1.0): Foundation - Complete ✅
- Phase 1 (v1.0.0): MVP - Current focus
- Phase 2 (v1.x): Enhancements - Future
- Phase 3 (v2.0): Advanced - Future
See ROADMAP.md for details.
- Be respectful and inclusive
- Welcome newcomers
- Provide constructive feedback
- Focus on what's best for the project
- Show empathy towards others
- Use clear, concise language
- Provide context in discussions
- Link to relevant documentation
- Be patient with response times
- Assume good intentions
Contributors will be recognized in:
- Release notes
- Contributors section (coming soon)
- Git commit history
- Check existing documentation in
/concept - Search closed issues
- Ask in issue discussions
- Tag maintainers in PRs
By contributing, you agree that your contributions will be licensed under the MIT License.
Thank you for contributing to the Gantt Chart Application!