Thanks for your interest in contributing to Browser Detect!
- Fork the repository and clone your fork
- Install dependencies:
composer install - Run the test suite:
composer test
- Create a branch from
main - Make your changes
- Add or update tests as needed
- Ensure all tests pass:
composer test - Commit using Conventional Commits
- Open a pull request against
mainwith a conventional commit formatted title
This project follows Conventional Commits. Every commit message must be structured as:
<type>[optional scope]: <description>
[optional body]
| Type | When to use |
|---|---|
feat |
A new feature |
fix |
A bug fix |
docs |
Documentation only |
refactor |
Code change that neither fixes a bug nor adds a feature |
test |
Adding or updating tests |
chore |
Maintenance tasks (deps, CI, config) |
perf |
Performance improvements |
feat: add detection for Arc browser
fix: correct tablet detection for iPad Air
docs: update installation instructions in README
refactor: extract version normalization into helper
test: add coverage for in-app browser detection
chore(deps): bump matomo/device-detector to ^7.0
- Follow the existing patterns in the codebase
- Keep changes focused — one concern per pull request
- Add tests for new functionality and bug fixes
composer test # All tests
./vendor/bin/phpunit --filter=TestClassName # Single test class
./vendor/bin/phpunit --filter=TestClassName::testMethod # Single test method