|
| 1 | +module.exports = { |
| 2 | + "parserOptions": { |
| 3 | + "ecmaVersion": 6, |
| 4 | + "sourceType": "module", |
| 5 | + "ecmaFeatures": { |
| 6 | + "jsx": true |
| 7 | + } |
| 8 | + }, |
| 9 | + "env": { |
| 10 | + "browser": true |
| 11 | + }, |
| 12 | + "globals": { |
| 13 | + "require": true, |
| 14 | + "module": true |
| 15 | + }, |
| 16 | + // Enables rules that report common problems, |
| 17 | + // see http://eslint.org/docs/rules/ for list |
| 18 | + "extends": "eslint:recommended", |
| 19 | + "rules": { //TODO: Extend rules in root folder |
| 20 | + // Enforce the use of variables within the scope they are defined |
| 21 | + "block-scoped-var": 2, |
| 22 | + // Enforce camelcase naming convention |
| 23 | + "camelcase": 2, |
| 24 | + // Enforce consistent spacing before and after commas |
| 25 | + "comma-spacing": 2, |
| 26 | + // Enforce at least one newline at the end of files |
| 27 | + "eol-last": 2, |
| 28 | + // Require the use of === and !== |
| 29 | + "eqeqeq": [2, "smart"], |
| 30 | + // Enforce consistent spacing before and after keywords |
| 31 | + "keyword-spacing": [2, { "before": true, "after": true }], |
| 32 | + // Disallow multiple empty lines |
| 33 | + "no-multiple-empty-lines": [2, { "max": 1, "maxEOF": 1, "maxBOF": 0 }], |
| 34 | + // Enforce the consistent use of the radix argument when using parseInt() |
| 35 | + "radix": 2, |
| 36 | + // Require or disallow semicolons instead of AS |
| 37 | + "semi": 2, |
| 38 | + // Enforce consistent spacing before and after semicolons |
| 39 | + "semi-spacing": 2, |
| 40 | + // Enforce consistent spacing before blocks |
| 41 | + "space-before-blocks": 2, |
| 42 | + // Enforce consistent spacing inside parentheses |
| 43 | + // "space-in-parens": [2, "always"], |
| 44 | + // Enforce the consistent use of either backticks, double, or single quotes |
| 45 | + "quotes": [2, "single", { "avoidEscape": true, "allowTemplateLiterals": true }] |
| 46 | + } |
| 47 | +}; |
0 commit comments