-
-
Save dzNavitski/4bc50813fcd6c5c4ba07a1af7f6a490e to your computer and use it in GitHub Desktop.
Prettier / Eslint Setup
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
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, | |
}, | |
} |
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
{ | |
"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" | |
} | |
} |
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
module.exports = { | |
semi: false, | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment