|
| 1 | +/* |
| 2 | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
| 3 | +title ESLint Configuration + |
| 4 | +project nord-hyper + |
| 5 | +repository https://github.com/arcticicestudio/nord-hyper + |
| 6 | +author Arctic Ice Studio + |
| 7 | + |
| 8 | +copyright Copyright (C) 2017 + |
| 9 | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
| 10 | +
|
| 11 | +[References] |
| 12 | +ESLint |
| 13 | + (http://eslint.org/docs/user-guide/configuring) |
| 14 | + (http://eslint.org/docs/user-guide/configuring#using-configuration-files) |
| 15 | + (http://eslint.org/docs/user-guide/configuring#specifying-environments) |
| 16 | + (http://eslint.org/docs/rules) |
| 17 | +*/ |
| 18 | +module.exports = { |
| 19 | + "env": { |
| 20 | + "node": true, |
| 21 | + "es6": true, |
| 22 | + "browser": true |
| 23 | + }, |
| 24 | + "parserOptions": { |
| 25 | + "ecmaVersion": 6, |
| 26 | + "ecmaFeatures": { |
| 27 | + "jsx": true |
| 28 | + } |
| 29 | + }, |
| 30 | + "extends": [ |
| 31 | + "eslint:recommended" |
| 32 | + ], |
| 33 | + "rules": { |
| 34 | + // Style Guide |
| 35 | + "array-bracket-spacing": ["error", "never"], |
| 36 | + "comma-dangle": ["error", "never"], |
| 37 | + "curly":["error", "all"], |
| 38 | + "func-call-spacing": ["error", "never"], |
| 39 | + "indent": ["error", 2], |
| 40 | + "linebreak-style": ["error", "unix"], |
| 41 | + "no-duplicate-imports": "error", |
| 42 | + "no-tabs": "error", |
| 43 | + "no-var": "error", |
| 44 | + "quotes": ["error", "double"], |
| 45 | + "semi": ["error", "always"], |
| 46 | + // Error Prevention |
| 47 | + "no-cond-assign": ["error", "always"], |
| 48 | + "no-console": "off", |
| 49 | + // Code Performance |
| 50 | + "global-require": "warn", |
| 51 | + // Documentation |
| 52 | + "require-jsdoc": ["warn", { |
| 53 | + "require": { |
| 54 | + "FunctionDeclaration": true, |
| 55 | + "MethodDefinition": false, |
| 56 | + "ClassDeclaration": true, |
| 57 | + "ArrowFunctionExpression": false |
| 58 | + } |
| 59 | + }], |
| 60 | + "valid-jsdoc": ["error", { |
| 61 | + "prefer": { |
| 62 | + "arg": "param", |
| 63 | + "argument": "param", |
| 64 | + "class": "constructor", |
| 65 | + "virtual": "abstract" |
| 66 | + }, |
| 67 | + "requireParamDescription": true, |
| 68 | + "requireReturnDescription": true |
| 69 | + }] |
| 70 | + }, |
| 71 | + "plugins": [ |
| 72 | + |
| 73 | + ] |
| 74 | +} |
0 commit comments