Thank you for your interest in contributing! This library values simplicity and focus - please help us maintain these principles.
# Clone the repository
git clone https://github.com/yourusername/binder.git
cd binder
# Run tests
go test ./...
# Run benchmarks
go test -bench=. -benchmem
# Check test coverage
go test -cover- Bug fixes with test cases demonstrating the issue
- Performance improvements with benchmark comparisons
- Documentation improvements and clarifications
- Test coverage for edge cases
- New features that expand scope beyond HTTP binding
- Validation logic (keep this in separate libraries)
- External dependencies (we want to stay at zero)
- Breaking API changes without strong justification
- Keep it focused: One issue per PR
- Add tests: All changes must include appropriate tests
- Run benchmarks: For performance-related changes, include before/after benchmarks
- Update docs: If behavior changes, update godoc comments
- Follow style: Use
gofmtand follow existing patterns
- Use standard Go conventions
- Keep functions small and focused
- Prefer clarity over cleverness
- Add comments only where the code isn't self-explanatory
- No unused code or commented-out blocks
All PRs must:
- Pass existing tests:
go test ./... - Include new tests for new behavior
- Maintain or improve code coverage
- Pass race condition checks:
go test -race ./...
When reporting issues, please include:
- Go version (
go version) - Minimal reproducible example
- Expected vs actual behavior
- Error messages if any
Before contributing, remember that Binder:
- Does one thing: binds HTTP data to structs
- Has zero dependencies (and will stay that way)
- Values simplicity over features
- Is designed for Go 1.22+ with native path parameters
If your contribution doesn't align with these principles, consider whether it might be better as a separate library that complements Binder rather than modifying it.
Feel free to open an issue for discussion before starting work on significant changes.