2020-08-01 16:48:10 +02:00
|
|
|
module.exports = {
|
|
|
|
root: true,
|
2020-08-01 19:01:51 +02:00
|
|
|
extends: [
|
|
|
|
'airbnb',
|
|
|
|
'plugin:flowtype/recommended',
|
|
|
|
'prettier',
|
|
|
|
'prettier/flowtype',
|
|
|
|
'prettier/react',
|
|
|
|
],
|
|
|
|
parser: 'babel-eslint',
|
|
|
|
plugins: ['flowtype'],
|
|
|
|
env: {
|
|
|
|
jest: true,
|
|
|
|
},
|
|
|
|
rules: {
|
2020-08-01 20:59:04 +02:00
|
|
|
'react/jsx-filename-extension': [1, {extensions: ['.js', '.jsx']}],
|
2020-08-02 19:43:06 +02:00
|
|
|
'react/static-property-placement': [2, 'static public field'],
|
2020-08-01 19:01:51 +02:00
|
|
|
'flowtype/define-flow-type': 1,
|
|
|
|
'flowtype/no-mixed': 2,
|
|
|
|
'flowtype/no-primitive-constructor-types': 2,
|
|
|
|
'flowtype/no-types-missing-file-annotation': 2,
|
|
|
|
'flowtype/no-weak-types': 2,
|
|
|
|
'flowtype/require-parameter-type': 2,
|
|
|
|
'flowtype/require-readonly-react-props': 0,
|
|
|
|
'flowtype/require-return-type': [
|
|
|
|
2,
|
|
|
|
'always',
|
|
|
|
{
|
|
|
|
annotateUndefined: 'never',
|
|
|
|
},
|
|
|
|
],
|
|
|
|
'flowtype/require-valid-file-annotation': 2,
|
|
|
|
'flowtype/type-id-match': [2, '^([A-Z][a-z0-9]+)+Type$'],
|
|
|
|
'flowtype/use-flow-type': 1,
|
|
|
|
'flowtype/valid-syntax': 1,
|
|
|
|
},
|
|
|
|
settings: {
|
|
|
|
flowtype: {
|
|
|
|
onlyFilesWithFlowAnnotation: false,
|
|
|
|
},
|
|
|
|
},
|
2020-08-02 19:43:06 +02:00
|
|
|
globals: {
|
|
|
|
fetch: false,
|
|
|
|
Headers: false,
|
|
|
|
},
|
2020-08-01 16:48:10 +02:00
|
|
|
};
|