2017-07-13 23:28:45 +02:00
|
|
|
{
|
|
|
|
"plugins": [
|
2018-10-09 14:24:17 +02:00
|
|
|
"babel",
|
2018-12-05 23:53:20 +01:00
|
|
|
"react",
|
2017-11-01 17:47:20 +01:00
|
|
|
"flowtype",
|
2018-12-03 07:18:45 +01:00
|
|
|
"jest",
|
2018-12-05 23:53:20 +01:00
|
|
|
"verdaccio",
|
|
|
|
"jsx-a11y"
|
2017-07-13 23:28:45 +02:00
|
|
|
],
|
|
|
|
"extends": [
|
|
|
|
"eslint:recommended",
|
|
|
|
"google",
|
|
|
|
"plugin:react/recommended",
|
2017-11-01 17:47:20 +01:00
|
|
|
"plugin:flowtype/recommended",
|
2018-08-15 22:17:41 +02:00
|
|
|
"plugin:jest/recommended",
|
2018-12-03 07:18:45 +01:00
|
|
|
"plugin:prettier/recommended",
|
2018-12-05 23:53:20 +01:00
|
|
|
"plugin:verdaccio/recommended",
|
|
|
|
"plugin:jsx-a11y/recommended"
|
2017-07-13 23:28:45 +02:00
|
|
|
],
|
2018-10-04 14:19:50 +02:00
|
|
|
"settings": {
|
|
|
|
"react": {
|
|
|
|
"pragma": "React", // Pragma to use
|
|
|
|
"version": "16.4.2", // React version
|
|
|
|
"flowVersion": "0.81.0" // Flow version
|
|
|
|
}
|
|
|
|
},
|
2017-09-02 21:20:59 +02:00
|
|
|
"parser": "babel-eslint",
|
2017-07-13 23:28:45 +02:00
|
|
|
"parserOptions": {
|
|
|
|
"sourceType": "module",
|
|
|
|
"ecmaVersion": 7,
|
|
|
|
"ecmaFeatures": {
|
|
|
|
"impliedStrict": true,
|
|
|
|
"jsx": true
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"env": {
|
|
|
|
"browser": true,
|
|
|
|
"node": true,
|
2017-11-01 17:47:20 +01:00
|
|
|
"es6": true,
|
|
|
|
"jest": true
|
2017-07-13 23:28:45 +02:00
|
|
|
},
|
2018-01-28 18:28:03 +01:00
|
|
|
"globals": {
|
|
|
|
"__APP_VERSION__": true
|
|
|
|
},
|
2017-07-13 23:28:45 +02:00
|
|
|
"rules": {
|
2018-10-09 14:24:17 +02:00
|
|
|
"babel/no-invalid-this": 1,
|
2018-08-15 22:17:41 +02:00
|
|
|
"prettier/prettier": ["error", null, "@prettier"],
|
2018-06-30 01:13:25 +02:00
|
|
|
"react/no-deprecated": 1,
|
2018-06-30 17:13:53 +02:00
|
|
|
"react/jsx-no-target-blank": 1,
|
2018-12-15 08:55:39 +01:00
|
|
|
"react/destructuring-assignment": ["warn", "always"],
|
|
|
|
"react/forbid-component-props": ["warn", { "forbid": ["style"] }],
|
|
|
|
"react/no-this-in-sfc": ["warn"],
|
|
|
|
"react/no-unsafe": ["warn"],
|
|
|
|
"react/sort-comp": ["warn", {
|
2018-12-05 23:53:20 +01:00
|
|
|
"order": [
|
|
|
|
"static-methods",
|
|
|
|
"lifecycle",
|
|
|
|
"render",
|
|
|
|
"everything-else",
|
|
|
|
"/^on.+$/",
|
|
|
|
"/^render.+$/"
|
|
|
|
]
|
|
|
|
}],
|
2018-12-15 08:55:39 +01:00
|
|
|
"react/void-dom-elements-no-children": ["warn"],
|
|
|
|
"react/no-did-mount-set-state": ["warn", "disallow-in-func"],
|
|
|
|
"react/jsx-wrap-multilines": ["warn",{
|
2018-12-05 23:53:20 +01:00
|
|
|
"declaration": "parens",
|
|
|
|
"assignment": "parens",
|
|
|
|
"return": "parens",
|
|
|
|
"arrow": "parens",
|
|
|
|
"condition": "parens",
|
|
|
|
"logical": "parens",
|
|
|
|
"prop": "parens"
|
|
|
|
}],
|
2018-12-15 08:55:39 +01:00
|
|
|
"react/jsx-boolean-value": ["warn", "always"],
|
|
|
|
"react/jsx-closing-tag-location": ["warn"],
|
|
|
|
// "react/jsx-curly-spacing": ["warn", "never"],
|
|
|
|
"react/jsx-equals-spacing": ["warn", "never"],
|
|
|
|
"react/jsx-first-prop-new-line": ["warn", "multiline-multiprop"],
|
|
|
|
"react/jsx-handler-names": ["warn"],
|
|
|
|
"react/jsx-indent": ["warn", 2],
|
|
|
|
"react/jsx-indent-props": ["warn", 2],
|
|
|
|
"react/jsx-key": ["warn"],
|
|
|
|
"react/jsx-max-depth": ["warn", { "max": 2}],
|
|
|
|
"react/jsx-max-props-per-line": ["warn", {"maximum": 3, "when": "multiline" }],
|
|
|
|
"react/jsx-no-bind": ["warn"],
|
|
|
|
"react/jsx-no-comment-textnodes": ["warn"],
|
|
|
|
"react/jsx-no-duplicate-props": ["warn"],
|
|
|
|
"react/jsx-no-literals": ["warn"],
|
|
|
|
"react/jsx-no-undef": ["warn"],
|
|
|
|
"react/jsx-one-expression-per-line": ["warn", {"allow": "literal"}],
|
|
|
|
"react/jsx-curly-brace-presence": ["warn", { "props": "always", "children": "ignore" }],
|
|
|
|
"react/jsx-pascal-case": ["warn"],
|
|
|
|
"react/jsx-props-no-multi-spaces": ["warn"],
|
|
|
|
"react/jsx-sort-default-props": ["warn"],
|
|
|
|
"react/jsx-sort-props": ["warn"],
|
|
|
|
"react/jsx-tag-spacing": ["warn", {
|
2018-12-05 23:53:20 +01:00
|
|
|
"closingSlash": "never",
|
|
|
|
"beforeSelfClosing": "always",
|
|
|
|
"afterOpening": "allow-multiline",
|
|
|
|
"beforeClosing": "allow"
|
|
|
|
}],
|
|
|
|
"no-useless-escape": 2,
|
|
|
|
"no-invalid-this": 0,
|
2017-07-13 23:28:45 +02:00
|
|
|
"handle-callback-err": 2,
|
|
|
|
"no-fallthrough": 2,
|
|
|
|
"no-new-require": 2,
|
2018-04-30 19:01:51 +02:00
|
|
|
"max-len": [2, 160],
|
2017-07-13 23:28:45 +02:00
|
|
|
"camelcase": 0,
|
2017-10-22 09:23:29 +02:00
|
|
|
"require-jsdoc": 0,
|
2017-10-22 11:53:16 +02:00
|
|
|
"valid-jsdoc": 0,
|
2017-07-13 23:28:45 +02:00
|
|
|
"prefer-spread": 1,
|
|
|
|
"prefer-rest-params": 1,
|
2018-06-11 22:22:45 +02:00
|
|
|
"linebreak-style": 0,
|
2018-12-15 08:55:39 +01:00
|
|
|
"quote-props":["warn", "as-needed"],
|
|
|
|
"verdaccio/jsx-no-style": ["warn"],
|
|
|
|
"verdaccio/jsx-spread": ["warn"],
|
|
|
|
"jest/expect-expect": ["warn"]
|
2017-07-13 23:28:45 +02:00
|
|
|
}
|
|
|
|
}
|