Adding basic ESLint config

This commit is contained in:
Peter deHaan 2017-06-07 11:26:40 -07:00
parent e077160a47
commit 837be5aa7b
No known key found for this signature in database
GPG key ID: F0FC6C01C6305097
4 changed files with 1225 additions and 747 deletions

38
.eslintrc.yml Normal file
View file

@ -0,0 +1,38 @@
env:
browser: true
es6: true
jquery: true
node: true
extends:
- eslint:recommended
- plugin:node/recommended
plugins:
- node
- security
root: true
rules:
security/detect-buffer-noassert: warn
security/detect-child-process: warn
security/detect-disable-mustache-escape: warn
security/detect-eval-with-expression: warn
security/detect-new-buffer: warn
security/detect-no-csrf-before-method-override: warn
security/detect-non-literal-fs-filename: warn
security/detect-non-literal-regexp: warn
security/detect-non-literal-require: warn
security/detect-possible-timing-attacks: warn
security/detect-pseudoRandomBytes: warn
security/detect-unsafe-regex: warn
eqeqeq: error
no-console: warn
no-path-concat: error
no-unused-vars: [error, {argsIgnorePattern: "^_|next"}]
no-var: error
one-var: [error, never]
prefer-const: error
quotes: [error, single]