First off, thank you for considering contributing to OTRUST! 🎉
This project adheres to a code of conduct. By participating, you are expected to uphold this code. Please be respectful and constructive in all interactions.
Before creating bug reports, please check existing issues as you might find that you don't need to create one.
When creating a bug report, please include:
- Clear title describing the issue
- Steps to reproduce the behavior
- Expected behavior vs actual behavior
- Environment details (Node version, OS, browser)
- Screenshots if applicable
Feature requests are welcome! Please:
- Check if it's already suggested in issues
- Describe the problem it solves
- Explain how you'd like it to work
- Consider if it fits the project scope
- Fork the repository
- Clone your fork locally
- Create a branch for your changes:
git checkout -b feature/amazing-feature
- Make your changes following the style guide below
- Run tests to ensure nothing breaks:
npm test npm run test:e2e - Commit with a clear message:
git commit -m 'Add amazing feature' - Push to your fork:
git push origin feature/amazing-feature
- Open a Pull Request with a clear description
# Clone the repo
git clone https://github.com/otrust-eu/core.git
cd core
# Install dependencies
npm install
# Copy environment template
cp .env.example .env
# Start development server
npm run dev
# Run tests
npm test- Use ES Modules (
import/export) - 2-space indentation
- Single quotes for strings
- Semicolons required
- Descriptive variable names
Follow Conventional Commits:
feat:- New featurefix:- Bug fixdocs:- Documentation onlystyle:- Formatting, no code changerefactor:- Code change, no feature/fixtest:- Adding testschore:- Maintenance tasks
Examples:
feat: add webhook notifications for claims
fix: handle empty hash in /claim endpoint
docs: update API examples in README
test: add E2E tests for verify page
src/ # Core application code
test/ # Test files (*.test.js)
test/e2e/ # End-to-end tests
web/ # Static frontend files
addons/ # Optional integrations
scripts/ # Build and maintenance scripts
- Unit tests: Test individual functions
- Integration tests: Test API endpoints
- E2E tests: Test user flows in browser
# Run all tests
npm run test:all
# Run with coverage
npm run test:coverage
# Run specific test file
npm test -- test/crypto.test.js
# Run E2E tests with UI
npm run test:e2e:ui- Open an issue
- Check the documentation
Thank you for contributing! 🙏