-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathindex.js
48 lines (41 loc) · 1.01 KB
/
index.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
module.exports = {
extends: require.resolve('./rules/style'),
env: {
node: true,
es6: true
},
parserOptions: {
ecmaVersion: 8
},
globals: {
// error types
ConfigNotDefinedError: true,
LoggerNotDefinedError: true,
ApiNotDefinedError: true,
ConfigValueError: true,
PackageNotDefinedError: true,
IllegalAccessError: true,
TimeoutError: true,
GraphCompletenessError: true,
NamespaceConflictError: true,
ValidationError: true,
TrailpackError: true,
// trails types
Service: true,
Controller: true,
Policy: true,
Model: true
},
rules: {
'no-console': 2,
'no-global-assign': 2,
// disallow modifying variables that are declared using const
'no-const-assign': 2,
// require let or const instead of var
'no-var': 2,
// suggest using of const declaration for variables that are never modified after declared
'prefer-const': 1,
// trails exposes process.env as trails.env
'no-process-env': 2
}
}