Skip to content

Instantly share code, notes, and snippets.

@dzNavitski
Forked from nikgraf/.eslintrc.js
Created October 25, 2017 03:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dzNavitski/4bc50813fcd6c5c4ba07a1af7f6a490e to your computer and use it in GitHub Desktop.
Save dzNavitski/4bc50813fcd6c5c4ba07a1af7f6a490e to your computer and use it in GitHub Desktop.
Prettier / Eslint Setup
module.exports = {
root: true, // make to not take in any user specified rules in parent folders
parser: 'babel-eslint',
extends: ['airbnb', 'prettier', 'prettier/flowtype', 'prettier/react'],
env: {
browser: true,
node: true,
jest: true,
},
plugins: ['react', 'import', 'flowtype'],
rules: {
'react/prop-types': 0,
'react/jsx-filename-extension': 0,
},
}
{
"scripts": {
"precommit": "lint-staged"
},
"lint-staged": {
"*.js": ["eslint"],
"*.{js,css}": ["prettier-eslint --list-different"]
},
"devDependencies": {
"babel-core": "^6.17.0",
"babel-eslint": "^8.0.1",
"eslint": "^4.8.0",
"eslint-config-airbnb": "^16.0.0",
"eslint-config-prettier": "^2.6.0",
"eslint-plugin-flowtype": "^2.39.1",
"eslint-plugin-import": "^2.7.0",
"eslint-plugin-jsx-a11y": "^6.0.2",
"eslint-plugin-react": "^7.4.0",
"husky": "^0.14.3",
"lint-staged": "^4.2.3",
"prettier-eslint": "^8.2.0",
"prettier-eslint-cli": "^4.4.0"
}
}
module.exports = {
semi: false,
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment