From e07423fa9fc1bf314de449b34017c57ebe6386ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?No=C3=A9=20Viricel?= Date: Wed, 25 Sep 2024 12:00:03 +0200 Subject: [PATCH] fix: wrong lint-staged statement --- README.md | 18 +++++++++++++++++- package.json | 4 +++- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 164a6c30..a40927e1 100644 --- a/README.md +++ b/README.md @@ -108,7 +108,23 @@ Header set Content-Security-Policy "frame-ancestors *" Vido is mainly building using: - [MapLibre GL JS](https://maplibre.org/maplibre-gl-js-docs/api/map/) -- [Nxut3](https://nuxt.com/) and [Vue3](https://vuejs.org/), using the Options API +- [Nuxt 3](https://nuxt.com/) and [Vue 3](https://vuejs.org/), using both Options API / Composition API + +### Setup hooks + +Ensure that `core.hooksPath` is properly setup ! + +From your project root run: + +```bash +git config core.hooksPath .git/hooks/ +``` + +Then update your hooks with the following command: + +```bash +yarn dlx simple-git-hooks +``` ``` # serve with hot reload at localhost:3000 diff --git a/package.json b/package.json index 530320b1..3174ebde 100644 --- a/package.json +++ b/package.json @@ -20,6 +20,7 @@ "start:cypress": "CONFIG=vidos-config-empty.json yarn build-fixture && yarn run cypress open", "lint": "yarn lint:js && yarn lint:style", "lint:js": "eslint .", + "lint:js:fix": "eslint --fix .", "lint:style": "stylelint --cache **/*.{vue,css,scss}", "test": "yarn test:cypress && yarn test:histoire", "test:cypress": "yarn build-fixture && yarn run cypress run", @@ -120,6 +121,7 @@ }, "lint-staged": { "*.{css,scss,vue}": "stylelint", - "*.{js,jsx,ts,tsx,vue}": "nuxi typecheck && eslint" + "*": "yarn nuxi typecheck .", + "*.{vue,ts,js}": "yarn lint:js:fix" } }