fix: Fix stylelint does not support html files
正在显示
.husky/lintstagedrc.js
deleted
100644 → 0
... | @@ -23,7 +23,7 @@ | ... | @@ -23,7 +23,7 @@ |
"lint:eslint": "eslint --cache --max-warnings 0 \"{src,mock}/**/*.{vue,ts,tsx}\" --fix", | "lint:eslint": "eslint --cache --max-warnings 0 \"{src,mock}/**/*.{vue,ts,tsx}\" --fix", | ||
"lint:prettier": "prettier --write \"src/**/*.{js,json,tsx,css,less,scss,vue,html,md}\"", | "lint:prettier": "prettier --write \"src/**/*.{js,json,tsx,css,less,scss,vue,html,md}\"", | ||
"lint:stylelint": "stylelint --cache --fix \"**/*.{vue,less,postcss,css,scss}\" --cache --cache-location node_modules/.cache/stylelint/", | "lint:stylelint": "stylelint --cache --fix \"**/*.{vue,less,postcss,css,scss}\" --cache --cache-location node_modules/.cache/stylelint/", | ||
"lint:lint-staged": "lint-staged -c ./.husky/lintstagedrc.js", | "lint:lint-staged": "lint-staged", | ||
"test:unit": "jest", | "test:unit": "jest", | ||
"test:unit-coverage": "jest --coverage", | "test:unit-coverage": "jest --coverage", | ||
"test:gzip": "npx http-server dist --cors --gzip -c-1", | "test:gzip": "npx http-server dist --cors --gzip -c-1", | ||
... | @@ -159,5 +159,29 @@ | ... | @@ -159,5 +159,29 @@ |
"homepage": "https://github.com/anncwb/vue-vben-admin", | "homepage": "https://github.com/anncwb/vue-vben-admin", | ||
"engines": { | "engines": { | ||
"node": "^12 || >=14" | "node": "^12 || >=14" | ||
}, | |||
"lint-staged": { | |||
"*.{js,jsx,ts,tsx}": [ | |||
"eslint --fix", | |||
"prettier --write" | |||
], | |||
"{!(package)*.json,*.code-snippets,.!(browserslist)*rc}": [ | |||
"prettier --write--parser json" | |||
], | |||
"package.json": [ | |||
"prettier --write" | |||
], | |||
"*.vue": [ | |||
"eslint --fix", | |||
"prettier --write", | |||
"stylelint --fix" | |||
], | |||
"*.{scss,less,styl,html}": [ | |||
"stylelint --fix", | |||
"prettier --write" | |||
], | |||
"*.md": [ | |||
"prettier --write" | |||
] | |||
} | } | ||
} | } |
请
注册
或者
登录
后发表评论