husky 需要有 .git
创建pre-commit
echo "npm run lint" > .husky/pre-commit
创建commit-msg
echo 'npx --no-install commitlint --edit "$1"' > .husky/commit-msg
.vscode
配置,可以配合vscode插件 - stylelint
执行lint
pnpm lint
pnpm lint:style
pnpm lint --fix
Look at the Nuxt 3 documentation to learn more.
Make sure to install the dependencies:
# pnpm
pnpm install
Check out the deployment documentation for more information.