-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.js.vue.dist
108 lines (107 loc) · 2.73 KB
/
.eslintrc.js.vue.dist
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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
module.exports = {
extends: [
'eslint:recommended',
'plugin:vue/recommended',
],
env: {
'es6': true,
'node': true,
'browser': true
},
rules: {
// Eslint rule modifications
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'no-new-func': 'error',
'prefer-arrow-callback': 'error',
'arrow-body-style': ['error', 'as-needed'],
'arrow-spacing': 'error',
'new-cap': 'error',
'no-eval': 'error',
'no-implied-eval': 'error',
'eqeqeq': 'error',
'no-with': 'error',
'no-warning-comments': 'error',
'max-len': ["error", {"code": 170}],
'no-unused-expressions': ['error', { 'allowTernary': true }],
'no-param-reassign': 'error',
'quote-props': ['error', 'consistent'],
// vue rule modification
"vue/order-in-components": ["error", {
"order": [
"el",
"name",
"key",
"parent",
"functional",
["delimiters", "comments"],
["components", "directives", "filters"],
"extends",
"mixins",
["provide", "inject"],
"layout",
"middleware",
"validate",
"scrollToTop",
"transition",
"loading",
"inheritAttrs",
"model",
["props", "propsData"],
"setup",
"asyncData",
"data",
"fetch",
"head",
"computed",
"methods",
"watch",
"watchQuery",
"emits",
"LIFECYCLE_HOOKS",
"ROUTER_GUARDS",
["template", "render"],
"renderError"
]
}],
'vue/html-closing-bracket-newline': ['error', {
'singleline': 'never',
'multiline': 'always'
}],
'vue/html-closing-bracket-spacing': ['error', {
'startTag': 'never',
'endTag': 'never',
'selfClosingTag': 'always'
}],
'vue/script-indent': ['error', 2, {
'baseIndent': 0,
'switchCase': 1,
'ignores': []
}],
'vue/html-indent': ['error', 2, {
"attribute": 1,
"baseIndent": 1,
"closeBracket": 0,
"alignAttributesVertically": true,
"ignores": []
}],
"vue/component-name-in-template-casing": ["error", "kebab-case", {
"registeredComponentsOnly": true,
"ignores": []
}],
//Disabled permanently
'vue/require-prop-types': 'off',
'vue/no-template-shadow': 'off',
'vue/no-v-html': 'off',
'vue/max-attributes-per-line': 'off',
'vue/attribute-hyphenation': 'off',
'prefer-destructuring': 'off',
'import/no-unresolved': 'off',
'no-invalid-this': 'off',
'no-plusplus': 'off',
'func-style': 'off',
},
parserOptions: {
parser: 'babel-eslint',
},
}