Thank you for your interest in contributing to the URI Parser!
-
Clone the repository
-
Install dependencies:
npm install
-
Run tests:
npm test -
Run tests in watch mode:
npm run test:watch
-
Run linter:
npm run lint
uri-parser/
├── src/
│ ├── lexer-types.ts # Token type definitions
│ ├── lexer.ts # Lexer implementation
│ ├── parser-types.ts # AST type definitions
│ ├── parser.ts # Parser implementation
│ ├── errors.ts # Error classes
│ └── index.ts # Public API exports
├── scripts/
│ └── build.mjs # Build script
└── tests/ # Test files
This parser follows the temporal-parser philosophy:
- Explicit tokens → shallow grammar → AST → later normalization
- Lexer is permissive and logic-light
- Parser builds a typed AST
- Lossless parsing (raw values preserved)
- Easy to extend with normalization passes
- Write tests for new features
- Ensure existing tests pass
- Aim for high code coverage
- Test edge cases and error conditions
- Follow the existing code style
- Use TypeScript strict mode
- Add JSDoc comments for public APIs
- Run
npm run lint:fixbefore committing
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests
- Run the test suite
- Submit a pull request
Feel free to open an issue for discussion!