Last active
March 6, 2019 01:11
-
-
Save skydiver/ebca1cfaa9dade7bc76e67a03060f5bb to your computer and use it in GitHub Desktop.
My VSCode project 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
# Editor configuration, see http://editorconfig.org | |
root = true | |
[*] | |
charset = utf-8 | |
indent_size = 2 | |
indent_style = space | |
insert_final_newline = false | |
trim_trailing_whitespace = true | |
[*.md] | |
max_line_length = off | |
trim_trailing_whitespace = true |
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": { | |
"browser": true, | |
"es6": true, | |
"node": true, | |
"jest": true | |
}, | |
extends: ["standard"], | |
plugins: ["standard", "react"], | |
rules: { | |
"no-var": "error", // optional, recommended when using es6+ | |
"no-unused-vars": 1, // recommended | |
"arrow-spacing": ["error", { before: true, after: true }], // recommended | |
indent: ["error", 2], | |
"comma-dangle": [ | |
"error", | |
{ | |
objects: "only-multiline", | |
arrays: "only-multiline", | |
imports: "never", | |
exports: "never", | |
functions: "never", | |
}, | |
], | |
// Martín M. | |
quotes: ["error", "single"], | |
// options to emulate prettier setup | |
semi: ["error", "always"], | |
"eol-last": ["error", "never"], | |
"max-len": ["error", { code: 80 }], | |
"template-curly-spacing": ["error", "always"], | |
"arrow-parens": ["error", "as-needed"], | |
// standard.js | |
"space-before-function-paren": [ | |
"error", | |
{ | |
named: "always", | |
anonymous: "always", | |
asyncArrow: "always", | |
}, | |
], | |
// standard plugin - options | |
"standard/object-curly-even-spacing": ["error", "either"], | |
"standard/array-bracket-even-spacing": ["error", "either"], | |
"standard/computed-property-even-spacing": ["error", "even"], | |
"standard/no-callback-literal": ["error", ["cb", "callback"]], | |
// react plugin - options | |
"react/jsx-uses-react": "error", | |
"react/jsx-uses-vars": "error", | |
}, | |
parser: "babel-eslint", | |
parserOptions: { | |
ecmaVersion: 8, // optional, recommended 6+ | |
}, | |
} |
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
{ | |
"css": { | |
"allowed_file_extensions": [ | |
"css", | |
"scss", | |
"sass", | |
"less" | |
], | |
"indent_size": 2 | |
}, | |
"js": { | |
"allowed_file_extensions": ["js", "json", "jshintrc", "jsbeautifyrc"], | |
"indent_size": 2 | |
} | |
} |
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
{ | |
"files.associations": { | |
"*.js": "javascriptreact" | |
}, | |
} |
Author
skydiver
commented
Jan 7, 2019
•
npm install --save-dev babel-eslint eslint eslint-config-standard eslint-plugin-import eslint-plugin-node eslint-plugin-promise eslint-plugin-react eslint-plugin-standard
mkdir .vscode &&
wget -O .vscode/settings.json https://gist.githubusercontent.com/skydiver/ebca1cfaa9dade7bc76e67a03060f5bb/raw/settings.json
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment