Commit 4f54462
authored
feat: add pre-commit hook with Prettier formatting (#1576)
This commit adds automatic code formatting on pre-commit using Husky and lint-staged. The hook will:
- Run Prettier on all staged files
- Automatically fix formatting issues when possible
- Ensure consistent code style across the codebase
Changes:
- Added lint-staged as a dev dependency
- Configured lint-staged to run Prettier with --write --ignore-unknown
- Created .husky/pre-commit hook to execute lint-staged
All files will be formatted according to the existing .prettierrc configuration before each commit.1 parent 6bda424 commit 4f54462
3 files changed
Lines changed: 233 additions & 110 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
30 | 31 | | |
31 | 32 | | |
32 | 33 | | |
33 | | - | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
34 | 38 | | |
0 commit comments