|
| 1 | +"use strict"; |
| 2 | + |
| 3 | +const OFF = 0; |
| 4 | +const WARN = 1; |
| 5 | +const ERROR = 2; |
| 6 | + |
| 7 | +module.exports = { |
| 8 | + extends: "airbnb", |
| 9 | + plugins: ["react", "jsx-a11y", "import"], |
| 10 | + |
| 11 | + rules: { |
| 12 | + quotes: [ |
| 13 | + ERROR, |
| 14 | + "double", |
| 15 | + { avoidEscape: true, allowTemplateLiterals: true }, |
| 16 | + ], |
| 17 | + indent: OFF, |
| 18 | + "no-tabs": OFF, |
| 19 | + "comma-dangle": [ERROR, "always-multiline"], |
| 20 | + "arrow-parens": [ERROR, "as-needed"], |
| 21 | + "import/no-extraneous-dependencies": OFF, |
| 22 | + "import/prefer-default-export": WARN, |
| 23 | + "import/first": OFF, |
| 24 | + "no-console": [WARN, { allow: ["warn", "error"] }], |
| 25 | + "no-confusing-arrow": OFF, |
| 26 | + |
| 27 | + // React & JSX |
| 28 | + // Our transforms set this automatically |
| 29 | + "react/jsx-indent": OFF, |
| 30 | + "react/jsx-indent-props": OFF, |
| 31 | + "react/jsx-closing-bracket-location": OFF, |
| 32 | + "react/prefer-stateless-function": WARN, |
| 33 | + |
| 34 | + // TODO |
| 35 | + "no-warning-comments": [ |
| 36 | + WARN, |
| 37 | + { terms: ["todo", "fixme"], location: "anywhere" }, |
| 38 | + ], |
| 39 | + }, |
| 40 | + settings: { |
| 41 | + "import/resolver": { |
| 42 | + webpack: { |
| 43 | + config: "webpack.config.js", |
| 44 | + }, |
| 45 | + }, |
| 46 | + }, |
| 47 | +}; |
0 commit comments