-
Notifications
You must be signed in to change notification settings - Fork 448
/
.eslintrc.js
87 lines (87 loc) · 2.22 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
83
84
85
86
87
module.exports = {
root: true,
env: {
browser: true,
node: true,
es6: true,
},
parser: 'vue-eslint-parser',
extends: ['@vue/prettier', 'prettier/@typescript-eslint', 'plugin:@typescript-eslint/recommended'],
plugins: ['@typescript-eslint'],
parserOptions: {
parser: '@typescript-eslint/parser',
},
rules: {
'prettier/prettier': 'error',
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'array-bracket-spacing': 2,
'no-var': 2,
'no-eval': 2,
'arrow-spacing': 2,
'block-spacing': 2,
'key-spacing': 2,
'brace-style': 2,
'vue/camelcase': 2,
'vue/require-component-is': 0,
'vue/require-default-prop': 0,
'comma-dangle': [2, 'always-multiline'],
'vue/eqeqeq': [
2,
'always',
{
null: 'ignore',
},
],
'object-curly-spacing': [2, 'always'],
'vue/singleline-html-element-content-newline': 0,
'vue/html-closing-bracket-newline': [
2,
{
singleline: 'never',
multiline: 'always',
},
],
'vue/max-attributes-per-line': 0,
'vue/html-self-closing': [
2,
{
html: {
void: 'always',
normal: 'never',
component: 'always',
},
svg: 'always',
math: 'always',
},
],
// https://github.com/typescript-eslint/typescript-eslint/tree/master/packages/eslint-plugin/docs/rules
'@typescript-eslint/camelcase': 0,
'@typescript-eslint/no-non-null-assertion': 0,
'@typescript-eslint/member-delimiter-style': [
2,
{
multiline: {
delimiter: 'none',
requireLast: true,
},
singleline: {
delimiter: 'semi',
requireLast: false,
},
},
],
'@typescript-eslint/no-unused-vars': [
0,
{
args: 'none',
},
],
'@typescript-eslint/interface-name-prefix': 0,
'@typescript-eslint/explicit-function-return-type': 0,
'@typescript-eslint/no-empty-function': 0,
'@typescript-eslint/no-var-requires': 0,
'@typescript-eslint/no-use-before-define': 0,
'@typescript-eslint/no-explicit-any': 0,
},
}