-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
96 lines (94 loc) · 2.61 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
88
89
90
91
92
93
94
95
96
module.exports = {
root: true,
env: {
node: true
},
extends: ["plugin:vue/essential", "@vue/airbnb"],
rules: {
// don't require .vue extension when importing
"import/extensions": [
"error",
"always",
{
js: "never",
vue: "never"
}
],
// disallow reassignment of function parameters
// disallow parameter object manipulation except for specific exclusions
"no-param-reassign": [
"error",
{
props: true,
ignorePropertyModificationsFor: [
"state", // for vuex state
"acc", // for reduce accumulators
"e" // for e.returnvalue
]
}
],
// allow optionalDependencies
"import/no-extraneous-dependencies": [
"error",
{
optionalDependencies: ["test/unit/index.js"]
}
],
// allow debugger during development
"no-debugger": process.env.NODE_ENV === "production" ? "error" : "off",
indent: ["error", 4],
"import/first": 0,
"import/named": 2,
"import/namespace": 2,
"import/default": 2,
"import/export": 2,
"import/extensions": 0,
"import/no-unresolved": 0,
"max-len": [
"error",
{
code: 7000,
ignoreComments: true,
ignoreStrings: true
}
],
"no-multi-spaces": "off",
"arrow-body-style": "off",
"comma-dangle": "off",
"no-param-reassign": [
"warn",
{
props: false
}
],
"linebreak-style": "off",
"arrow-parens": "off",
quotes: "off",
"keyword-spacing": "off",
"no-restricted-syntax": "off",
"guard-for-in": "off",
"space-before-blocks": "off",
"brace-style": "off",
"import/no-dynamic-require": "off",
"no-console": [
"warn",
{
allow: ["warn", "error"]
}
],
"no-shadow": [
"error",
{
allow: ["resolve", "reject", "done", "cb"]
}
],
"object-curly-newline": "off",
"semi": "off",
// allow debugger during development
"no-debugger": process.env.NODE_ENV === "production" ? 2 : 0,
"vue/max-attributes-per-line": "off"
},
parserOptions: {
parser: "babel-eslint"
}
};