Skip to content

Commit

Permalink
Run prettier --write on staged files
Browse files Browse the repository at this point in the history
  • Loading branch information
dotNomad committed Mar 29, 2024
1 parent a1cdd82 commit af85858
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
# npm run check-format
#!/usr/bin/env sh
. "$(dirname "$0")/_/husky.sh"

npx lint-staged
5 changes: 5 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@
"check-format": "prettier . --check",
"prepare": "husky"
},
"lint-staged": {
"*": [
"prettier --write --ignore-unknown"
]
},
"devDependencies": {
"husky": "^9.0.11",
"lint-staged": "^15.2.2",
Expand Down

0 comments on commit af85858

Please sign in to comment.