{ "parser": "babel-eslint", "ecmaFeatures": { "jsx": true, "modules": true }, "globals": { "Buffer": false, "window": false, "document": false, "location": false, "module": false, "require": false, "process": false, "console": false, "setTimeout": false, "clearTimeout": false, "setInterval": false, "clearInterval": false, "describe": false, "xdescribe": false, "it": false, "xit": false, "before": false, "xbefore": false, "after": false, "xafter": false, "beforeEach": false, "xbeforeEach": false, "afterEach": false, "xafterEach": false }, "rules": { "strict": 0, "indent": 2, // possible errors (http://eslint.org/docs/rules/) "comma-dangle": [1, "never"], "no-cond-assign": 1, "no-console": 1, "no-constant-condition": 1, "no-control-regex": 1, "no-debugger": 1, "no-dupe-args": 1, "no-dupe-keys": 1, "no-duplicate-case": 1, "no-empty-character-class": 1, "no-empty": 1, "no-ex-assign": 1, "no-extra-boolean-cast" :1, "no-extra-semi": 1, "no-func-assign": 1, "no-inner-declarations": 1, "no-invalid-regexp": 1, "no-irregular-whitespace": 1, "no-negated-in-lhs": 1, "no-obj-calls": 1, "no-regex-spaces": 1, "no-sparse-arrays": 1, "no-unreachable": 1, "use-isnan": 1, "valid-jsdoc": 1, "valid-typeof": 1, "no-unexpected-multiline": 1, // disabled possible errors "no-extra-parens": 0, // like having the extra parens in react component render functions // best practices (http://eslint.org/docs/rules/) "accessor-pairs": 2, "block-scoped-var": 2, "consistent-return": 2, "curly": [2, "multi-line"], "default-case": 2, "dot-notation": 2, "dot-location": [2, "property"], "eqeqeq": 2, "guard-for-in": 2, "no-alert": 2, "no-caller": 2, "no-div-regex": 2, // disabled: doing returns in if/else clauses // is really useful with async/await patterns // "no-else-return": 2, "no-empty-label": 2, "no-eq-null": 2, "no-eval": 2, "no-extend-native": 2, "no-extra-bind": 2, "no-fallthrough": 2, "no-floating-decimal": 2, "no-implicit-coercion": 2, "no-implied-eval": 2, // disabled: using this in the context of functions outside of // class-like structures is oftentimes useful, esp in testing // "no-invalid-this": 2, "no-iterator": 2, "no-labels": 2, "no-lone-blocks": 2, "no-loop-func": 2, "no-multi-str": 2, "no-native-reassign": 2, "no-new-func": 2, "no-new-wrappers": 2, "no-new": 2, "no-octal-escape": 2, "no-octal": 2, "no-param-reassign": 2, "no-proto": 2, "no-redeclare": 2, "no-return-assign": 2, "no-script-url": 2, "no-self-compare": 2, "no-sequences": 2, "no-throw-literal": 2, "no-unused-expressions": 2, "no-useless-call": 2, "no-void": 2, "no-warning-comments": 2, "no-with": 2, "radix": 2, "vars-on-top": 2, "wrap-iife": 2, "yoda": 2, // disabled best practices "complexity": [0, 2], "no-multi-spaces": 0, // disabled since we like to line up equals on a column basis "no-process-env": 0, // disabled since using process.env is too useful to disable // Variables (http://eslint.org/docs/rules/) "init-declarations": 2, "no-catch-shadow": 2, "no-delete-var": 2, "no-label-var": 2, "no-shadow-restricted-names": 2, // "no-shadow": 2, "no-undef-init": 2, "no-undef": 2, "no-undefined": 2, "no-unused-vars": [2, {"args": "after-used", "argsIgnorePattern": "^_"}], // disabled "no-use-before-define": 0, // Stylistic Issues (http://eslint.org/docs/rules/) "array-bracket-spacing": 2, "block-spacing": 2, "brace-style": 2, // disabled: there are are lots of webservices that // return JSON properties that are underscored // "camelcase": 2, "comma-spacing": 2, "comma-style": 2, "computed-property-spacing": 2, "consistent-this": 2, "eol-last": 2, // disabled: don't require function names for closures "func-names": 0, "func-style": [2, "expression"], "id-length": [2, { exceptions: ["_", "a", "b", "e", "p", "r", "x"] }], "id-match": 2, "indent": 2, "jsx-quotes": 2, // NOTE: open to turning align: "value" off on "key-spacing" // disabled: not behaving as expected, need to debug // "key-spacing": [2, { align: "value" }], "key-spacing": 0, // disabled: want flexibility in placing comments "lines-around-comment": 0, "linebreak-style": 2, // NOTE: open to increasing # of callbacks, but would like to keep it to 3 if possible "max-nested-callbacks": [2, 3], "new-cap": 2, "new-parens": 2, // disabled: want more flexibility than this allows for "newline-after-var": 0, "no-array-constructor": 2, "no-continue": 2, // disabled: sometimes inline comments are really helpful "no-inline-comments": 0, "no-lonely-if": 2, "no-mixed-spaces-and-tabs": [2, "smart-tabs"], "no-multiple-empty-lines": [2, { max: 2 }], "no-negated-condition": 2, "no-nested-ternary": 2, "no-new-object": 2, // disabled: no need to restrict ourselves... "no-restricted-syntax": 0, // disabled: prefer spaced func style "no-spaced-func": 0, // disabled: prefer the terseness of ternary operator in some cases "no-ternary": 0, "no-trailing-spaces": 2, // disabled: many webservices return underscored JSON properties //"no-underscore-dangle": 2, "no-unneeded-ternary": 2, "object-curly-spacing": [2, "always", { arraysInObjects: false }], // disabled "one-var": 0, "operator-assignment": 2, // disabled: undecided for now "operator-linebreak": 0, "padded-blocks": [2, "never"], "quote-props": [2, "as-needed"], "quotes": [2, "double", "avoid-escape"], "semi-spacing": 2, "semi": 2, // disabled: don't want to have to sort variables in declarations "sort-vars": 0, "space-after-keywords": 2, "space-before-blocks": 2, "space-before-function-paren": [2, "never"], "space-before-keywords": 2, "space-in-parens": [2, "never"], "space-infix-ops": 2, "space-return-throw-case": 2, "space-unary-ops": 2, "spaced-comment": 2, "wrap-regex": 2, // ECMAScript 6 (http://eslint.org/docs/rules/) // disabled: doesn't play nicely with the async keyword from ES7 "arrow-parens": 0, "arrow-spacing": 2, "constructor-super": 2, "generator-star-spacing": 2, "no-class-assign": 2, "no-const-assign": 2, "no-dupe-class-members": 2, "no-this-before-super": 2, "no-var": 2, "object-shorthand": 2, "prefer-arrow-callback": 2, // disabled: prefer not to make everything a const "prefer-const": 0, "prefer-reflect": 2, "prefer-spread": 2, "prefer-template": 2, "require-yield": 2, // react rules "react/display-name": [2, { acceptTranspilerName: true }], // disabled: no reason to restrict this for now "react/forbid-prop-types": 0, "react/jsx-boolean-value": [2, "never"], "react/jsx-closing-bracket-location": 2, "react/jsx-curly-spacing": [2, "always"], "react/jsx-indent-props": 2, // disabled: want flexibility for attributes "react/jsx-max-props-per-line": 0, "react/jsx-no-duplicate-props": 2, // disabled: want the flexibility of specifying literals "react/jsx-no-literals": 0, "react/jsx-no-undef": 2, // disabled: no need for props to be sorted "react/jsx-sort-prop-types": 0, // disabled: no need for props to be sorted "react/jsx-sort-props": 0, "react/jsx-uses-react": 2, "react/jsx-uses-vars": 1, // NOTE: sometimes this is useful, but just disable it on a case-by-case basis "react/no-danger": 2, "react/no-did-mount-set-state": 2, "react/no-did-update-set-state": 2, "react/no-direct-mutation-state": 2, // disabled: want to be able to have local component state "react/no-multi-comp": 0, "react/no-unknown-property": 2, // disabled: linter complaining that rule wasn't found //"react/prefer-es6-class": 2, "react/prop-types": 2, "react/react-in-jsx-scope": 2, // disabled: not sure how well this plays with webpack "react/require-extension": 0, "react/self-closing-comp": 2, // disabled: not ready to get that rigid yet "react/sort-comp": 0, "react/wrap-multilines": 2 }, "plugins": ["react"] }