Skip to content

Instantly share code, notes, and snippets.

@lannex
Last active August 18, 2021 12:55
Show Gist options
  • Save lannex/e87dad813b12b1e5752a0a96790d43e0 to your computer and use it in GitHub Desktop.
Save lannex/e87dad813b12b1e5752a0a96790d43e0 to your computer and use it in GitHub Desktop.
eslint for typescript
@types/eslint
@types/eslint-plugin-prettier
@typescript-eslint/eslint-plugin
@typescript-eslint/parser
eslint
eslint-config-airbnb
eslint-config-prettier
eslint-plugin-import
eslint-plugin-jsx-a11y
eslint-plugin-prettier
eslint-plugin-react
eslint-plugin-react-hooks
{
"env": {
"browser": true,
"es6": true,
"jest": true
},
"extends": [
"plugin:react/recommended",
"plugin:@typescript-eslint/recommended",
"airbnb",
"plugin:import/errors",
"plugin:import/warnings",
"plugin:import/typescript",
"prettier"
],
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaFeatures": {
"jsx": true
},
"ecmaVersion": 2018,
"sourceType": "module"
},
"plugins": ["react"],
"rules": {
"import/extensions": [
"error",
"ignorePackages",
{
"js": "never",
"jsx": "never",
"ts": "never",
"tsx": "never"
}
],
"react/jsx-filename-extension": [
2,
{ "extensions": [".js", ".jsx", ".ts", ".tsx"] }
],
"react/prop-types": 0,
"react/state-in-constructor": 0,
"react/static-property-placement": [2, "static public field"]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment