build: update eslint and prettier config
This commit is contained in:
+4
-27
@@ -1,30 +1,7 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
root: true,
|
extends: ["plugin:vue/vue3-recommended", "eslint:recommended"],
|
||||||
env: {
|
|
||||||
node: true,
|
|
||||||
},
|
|
||||||
extends: [
|
|
||||||
'plugin:vue/vue3-essential',
|
|
||||||
'eslint:recommended',
|
|
||||||
'plugin:prettier/recommended',
|
|
||||||
],
|
|
||||||
parserOptions: {
|
|
||||||
parser: '@babel/eslint-parser',
|
|
||||||
},
|
|
||||||
rules: {
|
rules: {
|
||||||
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
|
"no-console": process.env.NODE_ENV === "production" ? "warn" : "off",
|
||||||
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
|
"no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off",
|
||||||
'vue/multi-word-component-names': 'off',
|
|
||||||
},
|
},
|
||||||
overrides: [
|
};
|
||||||
{
|
|
||||||
files: [
|
|
||||||
'**/__tests__/*.{j,t}s?(x)',
|
|
||||||
'**/tests/unit/**/*.spec.{j,t}s?(x)',
|
|
||||||
],
|
|
||||||
env: {
|
|
||||||
jest: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
],
|
|
||||||
}
|
|
||||||
|
|||||||
+2
-1
@@ -2,5 +2,6 @@ module.exports = {
|
|||||||
semi: false,
|
semi: false,
|
||||||
trailingComma: "all",
|
trailingComma: "all",
|
||||||
singleQuote: true,
|
singleQuote: true,
|
||||||
tabWidth: 2
|
printWidth: 100,
|
||||||
|
tabWidth: 2,
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -14,6 +14,7 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite",
|
"dev": "vite",
|
||||||
"build": "vite build",
|
"build": "vite build",
|
||||||
|
"lint": "eslint \"src/**/*.{js,vue}\"",
|
||||||
"preview": "vite preview"
|
"preview": "vite preview"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
@@ -30,6 +31,8 @@
|
|||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@vitejs/plugin-vue": "^4.2.3",
|
"@vitejs/plugin-vue": "^4.2.3",
|
||||||
|
"eslint": "^8.50.0",
|
||||||
|
"eslint-plugin-vue": "^9.17.0",
|
||||||
"sass": "^1.68.0",
|
"sass": "^1.68.0",
|
||||||
"vite": "^4.4.5"
|
"vite": "^4.4.5"
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user