Skip to content

Instantly share code, notes, and snippets.

@mcmire
Last active January 9, 2019 01:34
Show Gist options
  • Save mcmire/3d03609d90d6fa9ecc58029f0ef00cbe to your computer and use it in GitHub Desktop.
Save mcmire/3d03609d90d6fa9ecc58029f0ef00cbe to your computer and use it in GitHub Desktop.
My ESLint configuration
---
env:
browser: true
node: true
es6: true
extends: eslint:recommended
globals:
module: true
require: true
parserOptions:
ecmaVersion: 2018
sourceType: module
rules:
array-bracket-spacing: error
array-callback-return: error
block-scoped-var: error
block-spacing: error
brace-style:
- error
- 1tbs
- { allowSingleLine: true }
camelcase: error
comma-dangle:
- error
- always-multiline
comma-style: error
complexity: error
curly: error
default-case: error
eol-last: error
eqeqeq:
- error
- smart
func-call-spacing: error
indent:
- error
- 2
- { SwitchCase: 1 }
max-len:
- error
-
code: 80
ignorePattern: "^\\s*(?:describe|it|import)"
ignoreComments: true
no-caller: error
no-catch-shadow: error
no-cond-assign:
- error
- except-parens
no-lonely-if: error
no-loop-func: error
no-multiple-empty-lines: error
no-param-reassign: error
no-redeclare: error
no-shadow:
- error
- { allow: ["_"] }
no-throw-literal: error
no-trailing-spaces: error
no-unneeded-ternary: error
no-unused-expressions: error
no-unused-vars:
- error
- { argsIgnorePattern: "^_" }
no-with: error
one-var:
- error
- never
prefer-spread: error
quotes:
- error
- double
- { avoidEscape: true }
require-await: error
semi:
- error
- always
- { omitLastInOneLineBlock: true }
sort-keys: error
sort-imports:
- error
- { ignoreCase: true }
sort-vars: error
space-before-blocks: error
vars-on-top: error
wrap-iife:
- error
- inside
yoda: error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment