Created
February 15, 2020 00:52
-
-
Save xinzhang/cb62a711d01d04a7fd008a25708f6428 to your computer and use it in GitHub Desktop.
setup prettier and eslint
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
| this is to setup | |
| * in vscode, install prettier, eslint plugin (remove beautifier) | |
| * npm install prettier eslint-config-prettier eslint-plugin-pretier --save-dev | |
| * command + "," to add formatOnSave true | |
| * add prettier.config.js | |
| ``` | |
| module.exports = { | |
| $schema: 'http://json.schemastore.org/prettierrc', | |
| arrowParens: 'always', | |
| printWidth: 88, | |
| singleQuote: true, | |
| tabWidth: 2, | |
| trailingComma: 'all', | |
| }; | |
| ``` |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
946c240a