Contributing
Thank you for your interest in contributing to DotPassport SDK!
Getting Started
Prerequisites
Node.js 18+
npm or yarn
Git
Setup
Fork the repository
Clone your fork:
git clone https://github.com/YOUR_USERNAME/dotpassport-sdk.git cd dotpassport-sdkInstall dependencies:
npm installCreate a branch:
git checkout -b feature/your-feature-name
Development
Project Structure
Commands
npm run build
Build the SDK
npm run dev
Start development mode
npm test
Run tests
npm run lint
Lint code
npm run format
Format code with Prettier
npm run typecheck
Run TypeScript checks
Running Tests
Code Style
TypeScript
Use TypeScript for all source files
Export types from public API
Prefer interfaces over type aliases for object shapes
Use strict mode
Naming Conventions
Files
kebab-case
api-client.ts
Classes
PascalCase
DotPassportClient
Functions
camelCase
createWidget
Constants
UPPER_SNAKE
DEFAULT_TTL
Types
PascalCase
ScoresResponse
Comments
Pull Request Process
Before Submitting
Run all checks:
Update documentation if you changed public APIs
Add tests for new features
Update CHANGELOG.md with your changes
PR Title Format
Use conventional commit format:
PR Description Template
Reporting Issues
Bug Reports
Include:
SDK version
Environment (browser, Node.js version)
Steps to reproduce
Expected vs actual behavior
Error messages/screenshots
Feature Requests
Include:
Use case description
Proposed solution
Alternative solutions considered
Documentation
Adding New Pages
Create the markdown file in
docs/Add entry to
SUMMARY.mdFollow existing page structure
Documentation Style
Use clear, concise language
Include code examples
Add links to related pages
Use tables for reference data
Release Process
Releases are managed by maintainers:
Update version in
package.jsonUpdate
CHANGELOG.mdCreate release PR
After merge, tag release
Publish to npm
Code of Conduct
Be respectful and inclusive
Give constructive feedback
Help others learn
Report unacceptable behavior
Getting Help
Discord: Join our community
GitHub Issues: Report bugs or request features
Email: [email protected]
License
By contributing, you agree that your contributions will be licensed under the MIT License.
Related
Last updated
