-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy path.eslintrc.cjs
35 lines (33 loc) · 979 Bytes
/
.eslintrc.cjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
require('@rushstack/eslint-patch/modern-module-resolution');
const path = require('node:path');
const createAliasSetting = require('@vue/eslint-config-airbnb/createAliasSetting');
module.exports = {
root: true,
env: {
node: true,
es2022: true,
},
extends: ['plugin:vue/vue3-recommended', '@vue/airbnb', 'prettier'],
rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'vue/eqeqeq': 'error',
'vue/no-reserved-component-names': 'off',
'space-infix-ops': ['error', { int32Hint: false }],
'brace-style': ['error', '1tbs', { allowSingleLine: false }],
'import/no-unresolved': 'error',
},
overrides: [
{
files: [
'**/__tests__/*.{j,t}s?(x)',
'**/tests/unit/**/*.spec.{j,t}s?(x)',
],
},
],
settings: {
...createAliasSetting({
'@': `${path.resolve(__dirname, './src')}`,
}),
},
};