eslint-config-picnic
Version:
Shared ESLint config for picnic
355 lines (353 loc) • 7.57 kB
YAML
parserOptions:
ecmaVersion: 6
ecmaFeatures:
arrowFunctions: true
binaryLiterals: true
blockBindings: true
classes: true
generators: true
objectLiteralShorthandMethods: true
objectLiteralShorthandProperties: true
objectLiteralComputedProperties: true
octalLiterals: true
templateStrings: true
unicodeCodePointEscapes: true
env:
node: true
browser: true
builtin: true
es6: true
plugins:
- lodash
- import
rules:
no-alert: 2
no-array-constructor: 2
no-bitwise: 0
no-caller: 2
no-cond-assign:
- 2
- "except-parens"
no-console: 0 # TODO make 2
no-constant-condition: 2
no-continue: 0
no-control-regex: 2
no-debugger: 2
no-delete-var: 2
no-div-regex: 2
no-dupe-keys: 2
no-dupe-args: 2
no-duplicate-case: 2
no-else-return: 0 # TODO: make 2
no-empty: 2
no-empty-character-class: 2
no-eq-null: 0
no-eval: 2
no-ex-assign: 2
no-extend-native: 2
no-extra-bind: 2
no-extra-boolean-cast: 2
no-extra-parens: 0 # TODO: make 2
no-extra-semi: 2
no-fallthrough: 0 # TODO: make 2
no-floating-decimal: 0 # TODO: make 2
no-func-assign: 2
no-implied-eval: 2
no-inline-comments: 0
no-inner-declarations:
- 2
- "functions"
no-invalid-regexp: 2
no-irregular-whitespace: 2
no-iterator: 2
no-label-var: 2
no-labels: 2
no-lone-blocks: 2
no-lonely-if: 0 # TODO: make 2
no-loop-func: 2
no-mixed-requires: 0 # TODO: make 2
no-mixed-spaces-and-tabs:
- 2
- false
linebreak-style:
- 2
- "unix"
no-multi-spaces: 2
no-multi-str: 2
no-multiple-empty-lines:
- 2
-
max: 2
no-native-reassign: 2
no-negated-in-lhs: 2
no-nested-ternary: 0 # TODO: Evaluate
no-new: 2
no-new-func: 2
no-new-object: 2
no-new-wrappers: 2
no-obj-calls: 2
no-octal: 2
no-octal-escape: 2
no-param-reassign: 0
no-path-concat: 0 # TODO: remove
no-plusplus: 0
no-process-env: 0 # TODO: make 2
no-proto: 2
no-redeclare: 2
no-regex-spaces: 2
no-reserved-keys: 0
no-restricted-modules: 0
no-return-assign: 2
no-script-url: 2
no-self-compare: 2
no-sequences: 2
no-shadow: 0 # TODO: make 2
no-shadow-restricted-names: 2
no-spaced-func: 2
no-sparse-arrays: 2
no-sync: 0 # TODO: make 2
no-ternary: 0
no-trailing-spaces: 2
no-this-before-super: 2
no-throw-literal: 2
no-undef: 2
no-undef-init: 2
no-undefined: 0 # TODO: make 2
no-unexpected-multiline: 2
no-underscore-dangle: 0
no-unneeded-ternary: 0 # TODO: make 2
no-unreachable: 2
no-unused-expressions: 0 # TODO: Evaluate if make 2
no-unused-vars:
- 2
-
vars: "all"
args: "none"
no-use-before-define: 0 # TODO: make 2
no-void: 0
no-var: 0 # TODO make 2
prefer-const: 0 # TODO make 2
no-warning-comments:
- 1
-
terms:
- "todo"
- "fix"
- "fixme"
location: "start"
no-with: 2
array-bracket-spacing:
- 2
- "never"
accessor-pairs: 0
block-scoped-var: 0 # TODO: make 2
brace-style:
- 2
- "1tbs"
-
allowSingleLine: true
camelcase: 0 # TODO: make 2
comma-dangle:
- 2
- "never"
comma-spacing: 2
comma-style:
- 2
- "last"
complexity: 0
computed-property-spacing:
- 2
- "never"
consistent-return: 0 # TODO: make 2
consistent-this:
- 0 # TODO: make 2
- "self"
constructor-super: 2
curly:
- 0 # TODO: make 2
- "all"
default-case: 0 # TODO: make 2
dot-location:
- 2
- "property"
dot-notation:
- 2
-
allowKeywords: true
eol-last: 2
eqeqeq:
- 2
- "allow-null"
func-names: 0 # TODO: Evaluate if good idea
func-style: 0 # TODO: evalate if require declaration style
generator-star-spacing: 2
guard-for-in: 0 # TODO: make 2
handle-callback-err:
- 0 # TODO: make 2
- "err"
indent:
- 2
- 2
- VariableDeclarator:
var: 2
let: 2
const: 3
SwitchCase: 2
key-spacing:
- 2
-
beforeColon: false
afterColon: true
lines-around-comment:
- 0 # TODO: Make 2 with next ESLint version
-
beforeBlockComment: true
allowBlockEnd: true
allowBlockStart: true
max-depth: 0
max-len:
- 0 # TODO: Evaluate whether we want 2
- 80
- 4
max-nested-callbacks:
- 0 # TODO: Make 2
- 2
max-params: 0
max-statements: 0
new-cap:
- 2
-
newIsCap: true
capIsNew: false
new-parens: 2
newline-after-var:
- 0 # TODO: make 2
- "always"
object-curly-spacing:
- 2
- "never"
object-shorthand: 0 # TODO: make 2
one-var: 0 # TODO: Evaluate with ES6
operator-assignment: 0
operator-linebreak:
- 2
- "after"
padded-blocks:
- 2
-
blocks: "never"
switches: "never"
classes: "never"
quote-props:
- 2
- "as-needed"
quotes:
- 2
- "single"
-
avoidEscape: true
radix: 0 # TODO: make 2
semi:
- 2
- "always"
semi-spacing:
- 2
-
before: false
after: true
sort-vars:
- 0 # TODO: make 2
-
ignoreCase: true
keyword-spacing: 2
space-before-blocks:
- 2
- "always"
space-before-function-paren:
- 2
- "never"
space-in-parens:
- 2
- "never"
space-infix-ops: 2
spaced-comment:
- 2
- "always"
-
markers:
- "*"
strict:
- 0 # TODO: switch to 2
- "global"
use-isnan: 2
valid-jsdoc:
- 0 # TODO: Make 2
-
prefer:
return: "returns"
requireReturn: false # TODO: remove
valid-typeof: 2
vars-on-top: 0 # TODO: Evaluate
wrap-iife:
- 2
- "inside"
wrap-regex: 0
yoda:
- 2
- "never"
import/export: 2
import/imports-first: 0 # TODO make 2
# import/namespace: 2 TODO add back in
import/newline-after-import: 0 # TODO make 2
import/no-duplicates: 2
import/no-unresolved:
- 2
-
commonjs: true
import/no-extraneous-dependencies: 2
lodash/callback-binding: 2
lodash/chain-style:
- 2
- "as-needed"
lodash/collection-method-value: 2
lodash/collection-return: 2
lodash/consistent-compose:
- 2
- "flow"
lodash/identity-shorthand:
- 2
- "always"
lodash/matches-shorthand:
- 2
- "always"
- 3
lodash/no-commit: 2
lodash/no-double-unwrap: 2
lodash/no-extra-args: 2
lodash/no-single-chain: 2
lodash/path-style:
- 2
- "string"
lodash/prefer-compact: 2
lodash/prefer-flat-map: 2
lodash/prefer-get:
- 2
- 3
lodash/prefer-is-nil: 2
lodash/prefer-lodash-chain: 2
lodash/prefer-matches:
- 2
- 3
lodash/prefer-over-quantifier: 2
lodash/prefer-reject:
- 2
- 3
lodash/prefer-startswith: 2
lodash/prefer-thru: 2
lodash/prefer-times: 2
lodash/prefer-wrapper-method: 2
lodash/prop-shorthand:
- 2
- "always"
lodash/unwrap: 2