-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.eslintrc.cjs
More file actions
26 lines (25 loc) · 903 Bytes
/
Copy path.eslintrc.cjs
File metadata and controls
26 lines (25 loc) · 903 Bytes
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
/* eslint-env node */
require('@rushstack/eslint-patch/modern-module-resolution')
module.exports = {
root: true,
'extends': [
'plugin:vue/vue3-essential',
'eslint:recommended',
'@vue/eslint-config-typescript',
'@vue/eslint-config-prettier'
],
parserOptions: {
ecmaVersion: 'latest'
},
rules: {
'curly': ['error', 'all'],
'indent': ['error', 2, { SwitchCase: 1 }],
'max-len': ['error', { code: 120 }],
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-plusplus': ['error', { allowForLoopAfterthoughts: true }],
'no-unused-vars': process.env.NODE_ENV === 'production' ? 'error' : 'warn',
'no-unreachable': process.env.NODE_ENV === 'production' ? 'error' : 'warn',
'no-undef': process.env.NODE_ENV === 'production' ? 'error' : 'warn',
},
}