Thank you for your interest in contributing to ValidKit! We welcome contributions from the community.
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
- Respect differing viewpoints and experiences
- Check if the bug has already been reported in Issues
- If not, create a new issue with:
- Clear title and description
- Steps to reproduce
- Expected vs actual behavior
- Node.js/TypeScript version
- Relevant code snippets
- Check if the feature has been requested
- Open a new issue with:
- Clear use case
- Proposed API design
- Benefits to users
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Add/update tests
- Update documentation
- Commit with clear messages (
git commit -m 'feat: add amazing feature') - Push to your fork (
git push origin feature/amazing-feature) - Open a Pull Request
# Clone your fork
git clone https://github.com/YOUR_USERNAME/validkit-typescript-sdk.git
cd validkit-typescript-sdk
# Install dependencies
npm install
# Build the project
npm run build
# Run tests in watch mode
npm run test:watch# Run all tests
npm test
# Run tests with coverage
npm run test:coverage
# Run specific test file
npm test -- src/client.test.ts
# Run tests in watch mode
npm run test:watchWe use:
- ESLint for linting
- Prettier for formatting
- TypeScript strict mode
Run all checks:
# Run linter
npm run lint
# Fix linting issues
npm run lint:fix
# Format code
npm run format
# Type check
npm run type-check# Build for production
npm run build
# Build in watch mode
npm run build:watch
# Build for different targets
npm run build:node # Node.js
npm run build:browser # Browser bundle- Add JSDoc comments to all public APIs
- Update README.md for user-facing changes
- Add examples for new features
- Ensure TypeScript types are well-documented
Follow conventional commits:
feat:New featurefix:Bug fixdocs:Documentation changestest:Test additions/changesrefactor:Code refactoringstyle:Code style changeschore:Maintenance tasksperf:Performance improvements
Examples:
feat: add webhook support for batch processing
fix: handle rate limit errors correctly
docs: update batch verification examples
perf: optimize batch processing for large datasets
- Keep the API surface small and focused
- Prioritize developer experience
- Maintain backward compatibility
- Use TypeScript types for better IDE support
- Follow existing naming conventions
- Write tests for all new features
- Maintain >90% code coverage
- Test edge cases and error scenarios
- Use descriptive test names
- Mock external dependencies
- Update version in
package.json - Update CHANGELOG.md
- Run
npm run build - Create release PR
- After merge, tag release:
git tag v1.2.3 - Push tags:
git push --tags - GitHub Actions will publish to npm
- Open an issue for questions
- Join our Discord
- Email: developers@validkit.com
Thank you for contributing! 🎉