.eslintrc.json 1.02 KB
Newer Older
1
{
2
3
4
5
  "extends": [
    "airbnb",
    "plugin:prettier/recommended"
  ],
6
  "root": true,
7
  "env": {
8
9
10
    "browser": true,
    "es6": true,
    "node": true
11
12
13
14
15
16
17
18
19
20
21
22
23
24
  },
  "globals": {
    "Drupal": true,
    "drupalSettings": true,
    "drupalTranslations": true,
    "domready": true,
    "jQuery": true,
    "_": true,
    "matchMedia": true,
    "Backbone": true,
    "Modernizr": true,
    "CKEDITOR": true
  },
  "rules": {
25
    "prettier/prettier": "error",
26
27
28
29
30
    "consistent-return": ["off"],
    "no-underscore-dangle": ["off"],
    "max-nested-callbacks": ["warn", 3],
    "import/no-mutable-exports": ["warn"],
    "no-plusplus": ["warn", {
31
32
      "allowForLoopAfterthoughts": true
    }],
33
34
35
    "no-param-reassign": ["off"],
    "no-prototype-builtins": ["off"],
    "valid-jsdoc": ["warn", {
36
37
38
39
40
      "prefer": {
        "returns": "return",
        "property": "prop"
      },
      "requireReturn": false
41
    }],
42
    "no-unused-vars": ["warn"],
43
    "operator-linebreak": ["error", "after", { "overrides": { "?": "ignore", ":": "ignore" } }]
44
45
  }
}