-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.eslintrc.js
82 lines (81 loc) · 1.73 KB
/
.eslintrc.js
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
// eslint-disable-next-line @typescript-eslint/no-var-requires
const { defineConfig } = require('eslint-define-config')
module.exports = defineConfig({
env: {
browser: true,
node: true,
},
globals: {
jest: 'readonly',
},
extends: [
'plugin:markdown/recommended',
'prettier',
],
overrides: [
{
files: '*.vue',
extends: [
'@vue/typescript/recommended',
'plugin:vue/recommended',
'@vue/typescript'
]
},
{
files: ['*.vue', '*.js'],
extends: [
'plugin:vue/essential',
'@vue/standard'
],
rules: {
'vue/max-attributes-per-line': [
2,
{
singleline: 20,
multiline: {
max: 1,
allowFirstLine: false
}
}
],
'vue/no-multiple-template-root': 0,
'vue/no-lone-template': 0,
'vue/no-v-model-argument': 0
}
},
{
files: ['*.ts', '*.tsx'],
extends: ['standard-with-typescript'],
parserOptions: {
project: './tsconfig.json',
ecmaFeatures: {
jsx: true
}
},
rules: {
'@typescript-eslint/strict-boolean-expressions': 0,
'@typescript-eslint/prefer-nullish-coalescing': 0,
'@typescript-eslint/naming-convention': 0,
'multiline-ternary': 0,
'no-void': 0
}
},
{
files: '*.spec.ts',
globals: {
describe: 'readonly',
it: 'readonly',
expect: 'readonly'
},
rules: {
'@typescript-eslint/no-floating-promises': 0
}
},
{
files: ['**/__tests__/**', '**/gulpfile.ts'],
rules: {
'no-console': 'off',
},
},
],
})