The following highlight some guidelines for contributing to .NET Hypermedia Toolkit and submitting pull requests.
.NET Hypermedia Toolkit aspires follow ideas set out by Bob Martin in Clean Code. As such, the following are some guidelines to think about as you code:
- Use pronounceable, meaningful names that reveal intentions.
- Code should read like a top-down narrative starting with required modules to make things easy to find.
- Use three or less method arguments.
- Stay DRY and keep methods, classes and modules sizes small.
- If you are explaining bad code, fix the code.
- Aspire to self-documenting variable and method names.
- Methods should call other methods vs. writing larger methods that violate SRP.
- Every method should be followed by any methods it calls (as the next level of abstraction).
- Fast - run quickly.
- Independent - not rely on previous tests.
- Repeatable - work in any environment.
- Self-validating - examples are written to document what passes.
- Timely - Follow TDD/BDD principles.