Contributing Guide
How to contribute to Emberly - setting up development environment, code standards, and submitting pull requests.
Thanks for your interest in contributing to Emberly! This guide explains how to set up your development environment, write code that matches our standards, and submit your changes.
Getting Started
Prerequisites
- Node.js 18+ (check with
node -v) - PostgreSQL 14+ (for database)
- Git (for version control)
- Rust 1.70+ (for Tauri desktop app, optional)
See the Development Setup Guide for detailed installation steps.
Development Workflow
1. Fork and Clone
2. Create a Feature Branch
3. Make Your Changes
Follow the standards below and commit regularly:
4. Test Your Changes
Before pushing, ensure your code works:
5. Push and Create Pull Request
Code Standards
TypeScript
All TypeScript code must pass type checking:
Guidelines:
- Use
strict: truein tsconfig - Don't use
anytypes (use unknown and narrow) - Export public APIs explicitly
- Use interfaces for public contracts
React Components
Components should be functional with proper TypeScript:
API Routes
Backend routes should follow REST conventions:
Route naming:
GET /api/resource— ListPOST /api/resource— CreateGET /api/resource/[id]— Get onePATCH /api/resource/[id]— UpdateDELETE /api/resource/[id]— Delete
Linting and Formatting
Configuration files:
.eslintrc.mjs— ESLint rulesprettier.config.js— Formatting rules
Testing
Adding Tests
Write tests for new features:
Running Tests
Git Commits
Use conventional commit messages:
Types:
feat:New featurefix:Bug fixdocs:Documentationrefactor:Code cleanupperf:Performance improvementtest:Testsci:CI/CD changes
Examples:
Pull Request Process
Before You Submit
-
Update main from upstream
-
Ensure all tests pass
-
Write a clear PR description
- What does this PR do?
- Why is it needed?
- How was it tested?
- Are there breaking changes?
PR Description Template
Code Review Process
-
Automatic checks run:
- TypeScript compilation
- Linting
- Tests
- Build verification
-
Team reviews code:
- Checks for correctness
- Suggests improvements
- Tests manually
-
Address feedback:
-
Merge once approved:
Documentation Updates
When adding features, update documentation:
TypeScript/API Docs
MDX Documentation
Create or update docs in /documentation/content/docs:
Common Tasks
Adding a Database Field
-
Update Prisma schema
-
Create migration
-
Update API types
-
Regenerate Prisma client
Adding a New API Endpoint
-
Create route file
-
Add types
-
Write tests
-
Document in API reference
Adding a New React Component
-
Create component
-
Write tests
-
Add to Storybook (if design component)
-
Use in app
Reporting Issues
Found a bug? Create an issue with:
-
Clear title
- Bad: "Doesn't work"
- Good: "Upload fails on Firefox with large files"
-
Description
- What were you trying to do?
- What happened?
- What should happen?
-
Reproduction Steps
- Step by step to reproduce
- Include exact commands/actions
-
Environment
- OS (Windows/Mac/Linux)
- Browser (if relevant)
- Node version
- Database version
-
Error Messages
- Full stack trace
- Console logs
- Network errors
Upload failed: EFBIG: file too large, open 'file.iso'
Getting Help
- Questions? Open a discussion on GitHub
- Need guidance? Ask in
/questionsor start a discussion - Found a bug? Create an issue with reproduction steps
- Want to pair? Message a maintainer on Discord
Recognition
Contributors are recognized in:
- CONTRIBUTORS.md — All contributors
- Release notes — For significant contributions
- GitHub — Automatically linked to PRs
Code of Conduct
All contributors must follow our Code of Conduct. This includes:
- Respectful communication
- Inclusive environment
- No harassment or discrimination
- Constructive feedback only
License
All contributions are made under the project's license. By submitting a PR, you agree to license your contribution under the same terms.
Questions?
- 📖 Development Setup
- GitHub Discussions
- Issue Tracker
- 💻 Git Help:
git help <command>
Thanks for contributing! 🎉