Created
July 11, 2018 12:52
-
-
Save vbguard/b22c260d316dbf1a4676c1fc510092a1 to your computer and use it in GitHub Desktop.
React ESLint and Prettier config
This file contains 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
// Install following packages | |
// yarn add --dev eslint prettier eslint-config-airbnb@^15.0.1 eslint-config-prettier eslint-plugin-prettier eslint-plugin-react eslint-plugin-import eslint-plugin-jsx-a11y@^5.1.1 | |
// or | |
// npm install --save-dev eslint prettier eslint-config-airbnb@^15.0.1 eslint-config-prettier eslint-plugin-prettier eslint-plugin-react eslint-plugin-import eslint-plugin-jsx-a11y@^5.1.1 | |
{ | |
"extends": ["airbnb", "prettier", "prettier/react"], | |
"plugins": ["prettier"], | |
"parser": "babel-eslint", | |
"parserOptions": { | |
"ecmaVersion": 2016, | |
"sourceType": "module", | |
"ecmaFeatures": { | |
"jsx": true | |
} | |
}, | |
"env": { | |
"es6": true, | |
"browser": true, | |
"node": true | |
}, | |
"rules": { | |
"react/jsx-filename-extension": [1, { "extensions": [".js", ".jsx"] }] | |
} | |
} | |
// TODO: | |
// eslint-config-airbnb@16.0.1 eslint-plugin-react@7.8.2 eslint-plugin-import eslint-plugin-jsx-a11y@6.0.3 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment