Skip to content

Commit

Permalink
chore: Added promise elint plugin.
Browse files Browse the repository at this point in the history
chore: Updated Babel.
  • Loading branch information
cb1kenobi committed Dec 17, 2018
1 parent c4dc24e commit 24cb5c4
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 28 deletions.
67 changes: 40 additions & 27 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -16,40 +16,53 @@
"plugins": [
"chai-expect",
"mocha",
"promise",
"security"
],
"root": true,
"rules": {
"array-bracket-spacing": [ "error", "always", { "objectsInArrays": true, "arraysInArrays": true } ],
"array-bracket-spacing": [ 'warn', 'always' ],
"brace-style": [ 2, "1tbs", { "allowSingleLine": true } ],
"camelcase": 0,
"chai-expect/missing-assertion": 2,
"chai-expect/terminating-properties": 1,
"curly": [ 2, "all" ],
"eol-last": 2,
"indent": [ 2, "tab", { "SwitchCase": 1 } ],
"camelcase": "off",
"chai-expect/missing-assertion": "error",
"chai-expect/terminating-properties": "warn",
"curly": [ "error", "all" ],
"eol-last": "error",
"indent": [ "error", "tab", { "SwitchCase": 1 } ],
"keyword-spacing": [ "error" ],
"linebreak-style": [ 2, "unix" ],
"max-len": [ 2, 200 ],
"no-case-declarations": 0,
"no-cond-assign": 0,
"no-console": 0,
"no-control-regex": 0,
"no-empty": 1,
"no-inner-declarations": 0,
"no-mixed-spaces-and-tabs": 2,
"no-multi-str": 2,
"no-multiple-empty-lines": 2,
"no-trailing-spaces": 2,
"no-unused-vars": 0,
"no-useless-escape": 1,
"quotes": [ 2, "single" ],
"semi": [ 2, "always" ],
"space-before-blocks": [ 2, "always" ],
"linebreak-style": [ "error", "unix" ],
"max-len": [ "error", 200 ],
"no-case-declarations": "off",
"no-cond-assign": "off",
"no-console": "off",
"no-control-regex": "off",
"no-empty": "warn",
"no-inner-declarations": "off",
"no-mixed-spaces-and-tabs": "error",
"no-multi-str": "error",
"no-multiple-empty-lines": "error",
"no-trailing-spaces": "error",
"no-unused-vars": "off",
"no-useless-escape": "warn",
"promise/always-return": "error",
"promise/no-return-wrap": "error",
"promise/param-names": "error",
"promise/catch-or-return": "error",
"promise/no-native": "off",
"promise/no-nesting": "warn",
"promise/no-promise-in-callback": "warn",
"promise/no-callback-in-promise": "warn",
"promise/avoid-new": "warn",
"promise/no-new-statics": "error",
"promise/no-return-in-finally": "warn",
"promise/valid-params": "warn",
"quotes": [ "error", "single" ],
"semi": [ "error", "always" ],
"space-before-blocks": [ "error", "always" ],
"space-before-function-paren": [ "error", { "anonymous": "always", "named": "ignore", "asyncArrow": "always" }],
"space-in-parens": [ "error", "never" ],
"space-infix-ops": 2,
"space-unary-ops": [ 2, { "nonwords": false, "overrides": {} } ],
"valid-jsdoc": [ 1, { "requireReturn": false, "requireReturnDescription": false } ]
"space-infix-ops": "error",
"space-unary-ops": [ "error", { "nonwords": false, "overrides": {} } ],
"valid-jsdoc": [ "warn", { "requireReturn": false, "requireReturnDescription": false } ]
}
}
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"source-map-support": "^0.5.9"
},
"devDependencies": {
"@babel/core": "^7.2.0",
"@babel/core": "^7.2.2",
"@babel/plugin-transform-modules-commonjs": "^7.2.0",
"@babel/register": "^7.0.0",
"ansi-colors": "^3.2.3",
Expand All @@ -42,6 +42,7 @@
"eslint": "^5.10.0",
"eslint-plugin-chai-expect": "^2.0.1",
"eslint-plugin-mocha": "^5.2.0",
"eslint-plugin-promise": "^4.0.1",
"eslint-plugin-security": "^1.4.0",
"fancy-log": "^1.3.3",
"fs-extra": "^7.0.1",
Expand Down
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1720,6 +1720,11 @@ eslint-plugin-mocha@^5.2.0:
dependencies:
ramda "^0.25.0"

eslint-plugin-promise@^4.0.1:
version "4.0.1"
resolved "https://registry.yarnpkg.com/eslint-plugin-promise/-/eslint-plugin-promise-4.0.1.tgz#2d074b653f35a23d1ba89d8e976a985117d1c6a2"
integrity sha512-Si16O0+Hqz1gDHsys6RtFRrW7cCTB6P7p3OJmKp3Y3dxpQE2qwOA7d3xnV+0mBmrPoi0RBnxlCKvqu70te6wjg==

eslint-plugin-security@^1.4.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/eslint-plugin-security/-/eslint-plugin-security-1.4.0.tgz#d4f314484a80b1b613b8c8886e84f52efe1526c2"
Expand Down

0 comments on commit 24cb5c4

Please sign in to comment.