Last active
September 12, 2020 13:29
-
-
Save hericke47/6583243d929987fe04a7ff22bd251a5e to your computer and use it in GitHub Desktop.
Eslint ReactJs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"env": { | |
"browser": true, | |
"es6": true, | |
"jest": true | |
}, | |
"extends": [ | |
"plugin:react/recommended", | |
"airbnb", | |
"plugin:@typescript-eslint/recommended", | |
"prettier/@typescript-eslint", | |
"plugin:prettier/recommended" | |
], | |
"globals": { | |
"Atomics": "readonly", | |
"SharedArrayBuffer": "readonly" | |
}, | |
"parser": "@typescript-eslint/parser", | |
"parserOptions": { | |
"ecmaFeatures": { | |
"jsx": true | |
}, | |
"ecmaVersion": 2018, | |
"sourceType": "module" | |
}, | |
"plugins": [ | |
"react", | |
"react-hooks", | |
"@typescript-eslint", | |
"prettier", | |
"import-helpers" | |
], | |
"rules": { | |
"prettier/prettier": "error", | |
"react/jsx-one-expression-per-line": "off", | |
"react/jsx-props-no-spreading": "off", | |
"react/prop-types": "off", | |
"react-hooks/rules-of-hooks": "error", | |
"react-hooks/exhaustive-deps": "warn", | |
"no-unused-expressions": "off", | |
"react/jsx-filename-extension": [1, { "extensions": [".tsx"] }], | |
"import/prefer-default-export": "off", | |
"import/no-duplicates": "off", | |
"@typescript-eslint/camelcase": "off", | |
"@typescript-eslint/no-use-before-define": "off", | |
"@typescript-eslint/explicit-function-return-type": [ | |
"error", | |
{ | |
"allowExpressions": true | |
} | |
], | |
"import/extensions": [ | |
"error", | |
"ignorePackages", | |
{ | |
"ts": "never", | |
"tsx": "never" | |
} | |
], | |
"import-helpers/order-imports": [ | |
"warn", | |
{ | |
"newlinesBetween": "always", | |
"groups": [ | |
"/^react$/", | |
"module", | |
["parent", "sibling", "index", "/^@shared/skylab/"], | |
["/^~/"] | |
], | |
"alphabetize": { "order": "ignore", "ignoreCase": true } | |
} | |
] | |
}, | |
"settings": { | |
"import/resolver": { | |
"typescript": {} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment