Skip to content

Instantly share code, notes, and snippets.

@jamesflorentino
Created December 10, 2016 06:16
Show Gist options
  • Save jamesflorentino/075664ffc1945bc5bd3a94484df29eb8 to your computer and use it in GitHub Desktop.
Save jamesflorentino/075664ffc1945bc5bd3a94484df29eb8 to your computer and use it in GitHub Desktop.
My current ESLint configuration file for backend Node.js projects
{
"extends": "eslint:recommended",
"env": {
"node": true,
"browser": true,
"es6": true
},
"parserOptions": {
"ecmaVersion": 2017,
"sourceType": "module"
},
"rules": {
"comma-dangle": ["error", "always-multiline"],
"comma-spacing": ["error", { "before": false, "after": true }],
"eol-last": ["error", "always"],
"indent": ["error", 2, { "MemberExpression": 1 }],
"no-multiple-empty-lines": ["error"],
"no-new-symbol": "error",
"no-trailing-spaces": ["error"],
"no-undef": ["error"],
"no-unused-vars": ["error"],
"object-curly-spacing": ["error", "always"],
"object-shorthand": "error",
"prefer-const": 2,
"quotes": ["error", "single"],
"semi": ["error", "never"],
"space-in-parens": ["error", "never"],
"strict": [2, "never"]
}
}
@goatandsheep
Copy link

"browser": true,

is this backend?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment