build: update eslint and prettier config

This commit is contained in:
mrholek
2023-09-26 17:57:51 +02:00
parent 5def136d9a
commit d9ec6a488f
3 changed files with 9 additions and 28 deletions
+4 -27
View File
@@ -1,30 +1,7 @@
module.exports = {
root: true,
env: {
node: true,
},
extends: [
'plugin:vue/vue3-essential',
'eslint:recommended',
'plugin:prettier/recommended',
],
parserOptions: {
parser: '@babel/eslint-parser',
},
extends: ["plugin:vue/vue3-recommended", "eslint:recommended"],
rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'vue/multi-word-component-names': 'off',
"no-console": process.env.NODE_ENV === "production" ? "warn" : "off",
"no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off",
},
overrides: [
{
files: [
'**/__tests__/*.{j,t}s?(x)',
'**/tests/unit/**/*.spec.{j,t}s?(x)',
],
env: {
jest: true,
},
},
],
}
};
+2 -1
View File
@@ -2,5 +2,6 @@ module.exports = {
semi: false,
trailingComma: "all",
singleQuote: true,
tabWidth: 2
printWidth: 100,
tabWidth: 2,
};
+3
View File
@@ -14,6 +14,7 @@
"scripts": {
"dev": "vite",
"build": "vite build",
"lint": "eslint \"src/**/*.{js,vue}\"",
"preview": "vite preview"
},
"dependencies": {
@@ -30,6 +31,8 @@
},
"devDependencies": {
"@vitejs/plugin-vue": "^4.2.3",
"eslint": "^8.50.0",
"eslint-plugin-vue": "^9.17.0",
"sass": "^1.68.0",
"vite": "^4.4.5"
}