Is your feature request related to a problem? Please describe.
Currently, code quality checks (linting, formatting, type checking) rely entirely on developers remembering to run them manually before pushing. This often leads to failed CI pipelines or inconsistent code styles making it into the repository because a step was skipped locally.
Describe the solution you'd like
I would like to integrate Husky to handle Git hooks automatically.
- pre-commit: Should run
lint-staged (formatting and linting) to ensure no bad code is committed.
- pre-push: (Optional but recommended) Should run type checks or unit tests to prevent broken builds from reaching the remote.
Describe alternatives you've considered
- Relying solely on CI/CD pipelines (feedback loop is too slow; developers have to wait for the build to fail).
- Manual enforcement (prone to human error).
Additional context
- We are using a Monorepo, so Husky needs to be configured at the root but trigger scripts capable of handling the workspace structure.
✅ Proof of Work
- Install Husky:
npm install --save-dev husky
- Initialize:
npx husky init
- Update
package.json scripts to include a prepare script.
Is your feature request related to a problem? Please describe.
Currently, code quality checks (linting, formatting, type checking) rely entirely on developers remembering to run them manually before pushing. This often leads to failed CI pipelines or inconsistent code styles making it into the repository because a step was skipped locally.
Describe the solution you'd like
I would like to integrate Husky to handle Git hooks automatically.
lint-staged(formatting and linting) to ensure no bad code is committed.Describe alternatives you've considered
Additional context
✅ Proof of Work
npm install --save-dev huskynpx husky initpackage.jsonscripts to include apreparescript.