Last active
June 2, 2019 14:28
-
-
Save robertoentringer/3b9a437c48a5c8ad9ddae8467fb875cb to your computer and use it in GitHub Desktop.
My eslint config to working with prettier.
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
module.exports = { | |
env: { | |
commonjs: true, | |
browser: true, | |
es6: true | |
}, | |
extends: ["eslint:recommended", "plugin:prettier/recommended"], | |
globals: { | |
Atomics: "readonly", | |
SharedArrayBuffer: "readonly", | |
chrome: "readonly" | |
}, | |
plugins: ["prettier", "html"], | |
parserOptions: { | |
ecmaVersion: 2018, | |
sourceType: "module" | |
}, | |
rules: { | |
"prettier/prettier": ["error", { semi: false, printWidth: 100 }], | |
"comma-dangle": ["error", "never"] | |
} | |
} |
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
module.exports = { | |
env: { | |
commonjs: true, | |
es6: true, | |
node: true, | |
}, | |
extends: ["eslint:recommended", "plugin:prettier/recommended"], | |
parserOptions: { | |
ecmaVersion: 2018, | |
sourceType: "module" | |
}, | |
plugins: ["prettier", "html"], | |
rules: { | |
"no-console": 0, | |
"prettier/prettier": ["error", { semi: false , printWidth: 100}], | |
}, | |
} |
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
npm install --save-dev eslint eslint-config-prettier eslint-plugin-html eslint-plugin-prettier prettier |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment