From beab6640fc0ba1fb62735e6faa8e740b2503b26c Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Fri, 20 Aug 2021 13:33:12 +0200 Subject: Squashed 'follow-redirects/' content from commit 422890d git-subtree-dir: follow-redirects git-subtree-split: 422890dae07034ae762b4a83f447833ac97b05dd --- .eslintrc | 203 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 203 insertions(+) create mode 100644 .eslintrc (limited to '.eslintrc') diff --git a/.eslintrc b/.eslintrc new file mode 100644 index 0000000..dcd6c44 --- /dev/null +++ b/.eslintrc @@ -0,0 +1,203 @@ +{ + extends: "eslint:recommended", + + env: { + node: true, + es6: true + }, + + rules: { + // Best Practices + accessor-pairs: "error", + array-callback-return: "error", + block-scoped-var: "error", + class-methods-use-this: "error", + complexity: "error", + consistent-return: "error", + curly: "error", + default-case: "error", + dot-location: ["error", "property"], + dot-notation: "error", + eqeqeq: "error", + guard-for-in: "error", + no-alert: "error", + no-caller: "error", + no-case-declarations: "error", + no-div-regex: "error", + no-else-return: "error", + no-empty-function: "error", + no-empty-pattern: "error", + no-eq-null: "error", + no-eval: "error", + no-extend-native: "error", + no-extra-bind: "error", + no-extra-label: "error", + no-fallthrough: "error", + no-floating-decimal: "error", + no-global-assign: "error", + no-implicit-coercion: "error", + no-implicit-globals: "error", + no-implied-eval: "error", + no-invalid-this: "error", + no-iterator: "error", + no-labels: "error", + no-lone-blocks: "error", + no-loop-func: "error", + no-magic-numbers: "off", + no-multi-spaces: "error", + no-multi-str: "error", + no-new: "error", + no-new-func: "error", + no-new-wrappers: "error", + no-octal: "error", + no-octal-escape: "error", + no-param-reassign: "off", + no-proto: "error", + no-redeclare: "error", + no-restricted-properties: "error", + no-return-assign: "error", + no-return-await: "error", + no-script-url: "error", + no-self-assign: "error", + no-self-compare: "error", + no-sequences: "error", + no-throw-literal: "error", + no-unmodified-loop-condition: "error", + no-unused-expressions: "error", + no-unused-labels: "error", + no-useless-call: "error", + no-useless-concat: "error", + no-useless-escape: "error", + no-useless-return: "error", + no-void: "error", + no-warning-comments: "error", + no-with: "error", + prefer-promise-reject-errors: "error", + radix: "error", + require-await: "error", + vars-on-top: "off", + wrap-iife: "error", + + // Strict Mode + strict: ["error", "never"], + + // Variables + init-declarations: "off", + no-catch-shadow: "error", + no-delete-var: "error", + no-label-var: "error", + no-restricted-globals: "error", + no-shadow: "error", + no-shadow-restricted-names: "error", + no-undef: "error", + no-undef-init: "error", + no-undefined: "off", + no-unused-vars: "error", + no-use-before-define: ["error", { "functions": false }], + + // Node.js + callback-return: "off", + global-require: "error", + handle-callback-err: "error", + no-buffer-constructor: "error", + no-mixed-requires: "error", + no-new-require: "error", + no-path-concat: "error", + no-process-env: "error", + no-process-exit: "error", + no-restricted-modules: "error", + no-sync: "error", + + // Stylistic Issues + array-bracket-newline: "error", + array-bracket-spacing: "error", + array-element-newline: "off", + block-spacing: "error", + brace-style: ["error", "stroustrup", { allowSingleLine: true }], + camelcase: "error", + capitalized-comments: "off", + comma-dangle: ["error", "always-multiline"], + comma-spacing: "error", + comma-style: "error", + computed-property-spacing: "error", + consistent-this: ["error", "self"], + eol-last: "error", + func-call-spacing: "error", + func-name-matching: "error", + func-names: "off", + func-style: ["error", "declaration"], + function-paren-newline: "error", + id-blacklist: "error", + id-length: "off", + id-match: "error", + implicit-arrow-linebreak: "error", + indent: ["error", 2], + jsx-quotes: "error", + key-spacing: "error", + keyword-spacing: "error", + line-comment-position: "off", + linebreak-style: "error", + lines-around-comment: "error", + lines-between-class-members: "error", + max-depth: "error", + max-len: "off", + max-lines: "off", + max-nested-callbacks: "error", + max-params: "error", + max-statements: "off", + max-statements-per-line: "error", + multiline-comment-style: ["error", "separate-lines"], + multiline-ternary: "off", + new-cap: "error", + new-parens: "error", + newline-per-chained-call: "off", + no-array-constructor: "error", + no-bitwise: "error", + no-continue: "error", + no-inline-comments: "off", + no-lonely-if: "error", + no-mixed-operators: "off", + no-mixed-spaces-and-tabs: "error", + no-multi-assign: "off", + no-multiple-empty-lines: "error", + no-negated-condition: "off", + no-nested-ternary: "error", + no-new-object: "error", + no-plusplus: "off", + no-restricted-syntax: "error", + no-tabs: "error", + no-ternary: "off", + no-trailing-spaces: "error", + no-underscore-dangle: "off", + no-unneeded-ternary: "error", + no-whitespace-before-property: "error", + nonblock-statement-body-position: "error", + object-curly-newline: "off", + object-curly-spacing: ["error", "always"], + object-property-newline: "off", + one-var: "off", + one-var-declaration-per-line: "error", + operator-assignment: "error", + operator-linebreak: ["error", "after", { overrides: { ":": "after" } }], + padded-blocks: ["error", "never"], + padding-line-between-statements: "error", + quote-props: ["error", "consistent-as-needed"], + quotes: "error", + require-jsdoc: "off", + semi: "error", + semi-spacing: "error", + semi-style: "error", + sort-keys: "off", + sort-vars: "error", + space-before-blocks: "error", + space-before-function-paren: ["error", {"anonymous": "always", "named": "never"}], + space-in-parens: "error", + space-infix-ops: "error", + space-unary-ops: "error", + spaced-comment: "error", + switch-colon-spacing: "error", + template-tag-spacing: "error", + unicode-bom: "error", + wrap-regex: "off", + }, +} -- cgit v1.2.3