Thank you for your interest in contributing to Datalayer Desktop! This document provides guidelines and instructions for contributing.
By participating in this project, you agree to abide by our Code of Conduct:
- Be respectful and inclusive
- Welcome newcomers and help them get started
- Focus on constructive criticism
- Accept feedback gracefully
Before creating a bug report:
- Check the existing issues
- Try the latest version
- Collect relevant information
Create a bug report with:
- Clear, descriptive title
- Steps to reproduce
- Expected vs actual behavior
- Screenshots if applicable
- Environment details (OS, Node version, etc.)
Feature requests should include:
- Clear use case explanation
- Why existing features don't solve it
- Possible implementation approach
- Mockups/examples if applicable
-
Fork & Clone
git clone https://github.com/your-username/desktop.git cd desktop -
Create a Branch
git checkout -b feature/your-feature-name # or git checkout -b fix/issue-description -
Make Changes
- Follow the coding standards
- Add tests if applicable
- Update documentation
-
Commit
git add . git commit -m "feat: add amazing feature" # or git commit -m "fix: resolve issue with..."
-
Push & Create PR
git push origin your-branch-name
See DEVELOPMENT.md for detailed setup instructions.
Quick start:
npm install
npm start- Use TypeScript for all new code
- Follow existing code style
- Use meaningful variable names
- Add TypeDoc comments for public APIs
/**
* Calculate the sum of two numbers.
*
* @param a - First number
* @param b - Second number
* @returns The sum of a and b
*/
export function add(a: number, b: number): number {
return a + b;
}- Use functional components with hooks
- Keep components focused and small
- Use proper TypeScript props interfaces
interface ButtonProps {
label: string;
onClick: () => void;
disabled?: boolean;
}
export const Button: React.FC<ButtonProps> = ({
label,
onClick,
disabled = false
}) => {
return (
<button onClick={onClick} disabled={disabled}>
{label}
</button>
);
};src/renderer/
βββ components/ # Reusable UI components
β βββ [feature]/ # Feature-specific components
βββ pages/ # Page-level components
βββ hooks/ # Custom React hooks
βββ utils/ # Utility functions
βββ services/ # API and service layers
βββ stores/ # State management
Before submitting a PR, run:
# Format code
npm run format
# Lint code
npm run lint:fix
# Type check
npm run type-check
# Run all checks
npm run check:fixnpm test- Place test files next to the code they test
- Name test files with
.test.tsor.spec.ts - Write clear test descriptions
describe('Calculator', () => {
it('should add two numbers correctly', () => {
expect(add(2, 3)).toBe(5);
});
it('should handle negative numbers', () => {
expect(add(-1, 1)).toBe(0);
});
});Add TypeDoc comments to:
- All exported functions
- Public class methods
- Component props interfaces
- Complex algorithms
Update README.md when:
- Adding new features
- Modifying system requirements
The project uses TypeDoc:
npm run docs- Automated Checks - CI runs on all PRs
- Code Review - Maintainer reviews code
- Testing - Manual testing if needed
- Merge - Squash and merge to main
See RELEASE.md for release procedures.
- Discord: Join our Discord
- Discussions: GitHub Discussions
- Issues: GitHub Issues
By contributing, you agree that your contributions will be licensed under the BSD-3-Clause License.
Thank you for contributing to Datalayer Desktop! π