Skip to content

Instantly share code, notes, and snippets.

@cannap
Created August 19, 2017 00:04
Show Gist options
  • Save cannap/f37bfcc9e7981f2edc73e8a552523a42 to your computer and use it in GitHub Desktop.
Save cannap/f37bfcc9e7981f2edc73e8a552523a42 to your computer and use it in GitHub Desktop.
eslint standard vscode fix
// http://eslint.org/docs/user-guide/configuring
module.exports = {
root: true,
parser: 'babel-eslint',
parserOptions: {
sourceType: 'module'
},
env: {
browser: true
},
// https://github.com/feross/standard/blob/master/RULES.md#javascript-standard-style
extends: 'standard',
// required to lint *.vue files
plugins: ['html'],
// add your custom rules here
rules: {
// allow paren-less arrow functions
'arrow-parens': 0,
// allow async-await
'generator-star-spacing': 0,
// allow debugger during development
'no-debugger': process.env.NODE_ENV === 'production' ? 2 : 0,
singleQuote: true,
'space-before-function-paren': ['error', 'always'],
'prettier/prettier': [
'error',
{
singleQuote: true,
'space-before-function-paren': ['error', 'always']
}
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment