docs: Update Husky setup commands for PNPM users (#16943)

- Replace `npx husky init` with `pnpm exec husky init`
- Update installation command to use pnpm
- Add PNPM-specific pre-commit hook setup command
This commit is contained in:
seyeong authored and GitHub committed 2024-12-21 15:31:49 +09:00
1 parent 0015a83d93
commit cf00f641b5
1 file changed
+1 -1
+1 -1
View File
@@ -151,7 +151,7 @@ For example, you can do the following to have Prettier run before each commit:
```bash
pnpm add --save-dev husky lint-staged
npx husky init
pnpm exec husky init
node --eval "fs.writeFileSync('.husky/pre-commit','pnpm exec lint-staged\n')"
```