Welcome Contributors
Thank you for considering contributing to RAADS-R Self-Host! This project aims to provide an accurate, accessible, and privacy-focused implementation of the RAADS-R screening questionnaire.This is a clinical tool. All contributions should prioritize accuracy, accessibility, and user privacy.
Code of Conduct
By participating in this project, you agree to:- Be respectful and inclusive
- Focus on what’s best for the community
- Show empathy towards other contributors
- Accept constructive criticism gracefully
- Prioritize clinical accuracy and user privacy
How to Contribute
Reporting Bugs
Before submitting a bug report:Reproduce the Bug
Ensure you can consistently reproduce the issue:
- What steps trigger the bug?
- What did you expect to happen?
- What actually happened?
- What browser/OS are you using?
Suggesting Features
Feature requests should:- Align with the project’s privacy-first philosophy
- Maintain clinical accuracy of the instrument
- Improve accessibility or user experience
- Be described clearly with use cases
Submitting Code Changes
Create a Branch
feature/- New featuresfix/- Bug fixesdocs/- Documentation updatesrefactor/- Code refactoringtest/- Test additions or fixes
Make Your Changes
- Write clean, readable TypeScript code
- Follow existing code style and conventions
- Add comments for complex logic
- Update tests if needed
Commit Your Changes
Use clear, descriptive commit messages:Commit message format:
feat:- New featurefix:- Bug fixdocs:- Documentationtest:- Test changesrefactor:- Code refactoringstyle:- Formatting, no code change
Development Standards
Code Quality
- TypeScript: Use strict typing, avoid
any - Components: Keep components focused and single-purpose
- Hooks: Extract reusable logic into custom hooks
- Accessibility: Maintain WCAG 2.1 AA compliance
- Performance: Avoid unnecessary re-renders and computations
Testing Requirements
All code changes should include appropriate tests:- Unit Tests: Test individual functions and logic
- Integration Tests: Test component interactions
- Golden Tests: Validate against known correct outputs
Documentation
Document your changes:- Code Comments: Explain “why” not “what”
- JSDoc: Add for public functions
- README Updates: For feature additions
- Type Definitions: Keep TypeScript types accurate
Clinical Accuracy Guidelines
If your contribution involves:Scoring Logic
- Cross-reference with the original RAADS-R paper
- Validate against golden test vectors
- Ensure both scoring engines (
scoring.tsandscoring-alt.ts) remain synchronized - Document the clinical justification
Question Text
- Preserve the exact clinical wording from the published instrument
- Any modifications should be clearly documented and justified
- Update tests to reflect changes
Thresholds
- Only modify based on validated research
- Include citations in your PR description
- Update documentation to explain the change
Privacy & Security
This project is privacy-first. Contributions must:- Never add external API calls (except for static file serving)
- Never add tracking or analytics
- Never add cookies (beyond optional localStorage)
- Keep all data client-side
- Maintain opt-in consent for any data persistence
Pull Request Checklist
Before submitting your PR, ensure:- Code follows existing style and conventions
- All tests pass (
npm run test) - No linting errors (
npm run lint) - Production build works (
npm run build) - Changes are documented (code comments, README, etc.)
- Commit messages are clear and descriptive
- PR description explains the change and why it’s needed
- Screenshots included for UI changes
- No breaking changes (or clearly documented if necessary)
- Privacy principles maintained (no tracking, no external calls)
Review Process
Getting Help
If you need help:- Documentation: Check the Development Setup and Project Structure guides
- Questions: Open a GitHub issue with the “question” label
- Discussion: Start a discussion in GitHub Discussions
We appreciate all contributions, whether it’s code, documentation, bug reports, or feature ideas. Thank you for helping make this tool better!
Licence
By contributing to this project, you agree that your contributions will be licensed under the CC BY-NC 4.0 licence. The RAADS-R instrument is from a published research paper and is used under the Creative Commons Attribution-NonCommercial licence.Attribution
Significant contributors may be recognized in the project README. Contributions are tracked through Git commit history.Next Steps
- Set up your Local Development Environment
- Understand the Project Structure
- Learn about Customization Options