forked from MarkBind/markbind
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
61 lines (60 loc) · 2.23 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
/* eslint quote-props: ["error", "always"] */
/* eslint quotes: ["error", "double"] */
module.exports = {
"env": {
"node": true,
"es6": true,
"jest": true,
},
"plugins": ["lodash"],
"extends": ["airbnb-base", "plugin:lodash/recommended"],
"rules": {
"array-bracket-newline": ["error", { "multiline": true }],
"arrow-parens": ["error", "as-needed", { "requireForBlockBody": true }],
"func-names": "off",
"no-else-return": ["error", { "allowElseIf": true }],
"no-underscore-dangle": "off",
"function-paren-newline": "off",
"implicit-arrow-linebreak": "off",
"indent": [
"error",
2,
{
"CallExpression": { "arguments": "first" },
"FunctionDeclaration": { "parameters": "first" },
"FunctionExpression": { "parameters": "first" },
},
],
"lodash/prefer-lodash-method": [0],
"lodash/prefer-noop": [0],
"max-len": ["error", { "code": 110 }],
"no-param-reassign": ["error", { "props": false }],
"operator-linebreak": ["error", "before"],
// override airbnb-base dev dependencies, latest version does not white list __mocks__
"import/no-extraneous-dependencies": [
"error", {
"devDependencies": [
"test/**", // tape, common npm pattern
"tests/**", // also common npm pattern
"spec/**", // mocha, rspec-like pattern
"**/__tests__/**", // jest pattern
"**/__mocks__/**", // jest pattern
"test.{js,jsx}", // repos with a single test file
"test-*.{js,jsx}", // repos with multiple top-level test files
"**/*.{test,spec}.{js,jsx}", // tests where the extension denotes that it is a test
"**/jest.config.js", // jest config
"**/webpack.config.js", // webpack config
"**/webpack.config.*.js", // webpack config
"**/rollup.config.*.js", // rollup config
"**/rollup.config.*.js", // rollup config
"**/gulpfile.js", // gulp config
"**/gulpfile.*.js", // gulp config
"**/Gruntfile{,.js}", // grunt config
"**/protractor.conf.js", // protractor config
"**/protractor.conf.*.js", // protractor config
],
"optionalDependencies": false,
},
],
},
};