nuxt / create-nuxt-app

Create Nuxt.js App in seconds.
MIT License
3.48k stars 428 forks source link

lint-staged not working on fresh installations #956

Open jahvi opened 1 year ago

jahvi commented 1 year ago

Versions

Reproduction

See below.

Steps to reproduce

  1. Run npx create-nuxt-app nuxt2
  2. In the "Linting tools:" prompt choose "Prettier" and "Lint staged files", the rest doesn't matter.
  3. After installation update "index.vue" file and commit

What is Expected?

Changed files should be linted

What is actually happening?

Files are not linted.

It looks like husky, lint-staged and prettier are installed fine and the package.json file gets modified accordingly but the pre-commit hook doesn't trigger.