sourcecred/.eslintrc.js
Dandelion Mané 7259233f82
Prepare to enable flow-type eslint rules (#848)
This commit upgrades the flow-type eslint plugin to latest, and writes
new rules into the eslintrc. To keep the diff clean, the rules are
disabled: I will turn them on individually (fixing errors) in followon
commits.

Test plan: `yarn test`.
Uncommenting the lines produces many lint errors (but the linter still operates as expected).
2018-09-17 14:11:39 -07:00

23 lines
592 B
JavaScript

// @flow
module.exports = {
parser: "babel-eslint",
plugins: ["flowtype"],
extends: "react-app",
rules: {
"no-unused-vars": [
"warn",
{
argsIgnorePattern: "^_$|^_unused_",
varsIgnorePattern: "^_$|^_unused_",
caughtErrorsIgnorePattern: "^_$|^_unused_",
},
],
"no-use-before-define": ["off"],
"no-useless-constructor": ["off"],
// TODO(@decentralion): Enable this rule.
// "flowtype/no-mutable-array": [2],
// TODO(@decentralion): Enable this rule.
// "flowtype/require-exact-type": [2, "always"],
},
};