Skip to content

Latest commit

Β 

History

History
71 lines (50 loc) Β· 2.67 KB

File metadata and controls

71 lines (50 loc) Β· 2.67 KB

Contibuting guide πŸ’ͺ

Thank you for your willingness to contribute and even taking your time to read this guide.

Documentation πŸ“š

Documentation is hosted in a separate repository, that acts as my portfolio/home page.

Code πŸ§‘β€πŸ’»

To provide a code contribution, please create a pull request and fill out the pull request template.

Pre-requisites πŸ‘€

  • pnpm (PR's with incompatible lockfile due to different node package manager will not be accepted)

Contribution workflow πŸ“

After cloning the repository and doing pnpm install you're free to do any changes as deemed necessary.

  1. Add individual changes (please split bigger changes into smaller chunks, instead of single giant commit)
  2. Run pnpm cz to trigger the interactive cli to make sure your commits match the project rules
  3. Push your changes - This will trigger automatic linting and test check to make sure your PR didn't break anything

You do not need to bump any versions or deploy anything. This will be done automatically in the next release.

Acceptence criteria βœ…

  1. Adding any additional dependencies to the core package will result in closing the PR (unless a good reason is provided)
  2. Pull requests not adhering to the pull request template will be closed
  3. Disabling eslint / ts rules must always be accompanied with a good reason as to why the rule is being disabled.

Additonal information ℹ️

Here are some useful commands (these will trigger and cache in all packages automatically, via turborepo. Consider these commands as global unless stated otherwise)

Command Description
pnpm install Installs dependencies
pnpm clean Removes node_modules and pnpm-lock.yaml
pnpm lint Runs eslint
pnpm format Runs prettier
pnpm test Runs vitest

Here's the project structure (just the most important parts)

πŸ“ .github # CI/CD workflows and templates
πŸ“ packages
  πŸ“ core # the main @hulla/api package
  πŸ“ request # @hulla/api-request
  πŸ“ query # @hulla/api-query
  πŸ“ swr # @hulla/api-swr
βŽ— .eslintrc # shared eslint configuration
βŽ— .prettierrc # shared prettier configuration
βŽ— tsconfig.json # shared typescript configuration
βŽ— turbo.json # turborepo configuration

Each package has a following structure

πŸ“ src # source code that's transpited
  βŽ— index.ts # main export file
  βŽ— ... # other files
πŸ“ tests
  βŽ— {name}.test.ts # matching test coverage for src file name