{ "plugins": [ "jsdoc" ], "extends": [ // "plugin:unicorn/recommended", "eslint:recommended" ], "env": { "browser": true, "commonjs": true, "es6": true, "node": true }, "parserOptions": { "ecmaVersion": 11, "ecmaFeatures": { "jsx": false }, "sourceType": "module" }, "rules": { "array-callback-return": "error", "func-call-spacing": [ "error", "never" ], "comma-spacing": [ "error", { "before": false, "after": true } ], "space-infix-ops": "error", "keyword-spacing": [ "error", { "before": true } ], "indent": [ "error", 2, { "SwitchCase": 1 } ], "yoda": "error", "wrap-iife": [ "error", "inside" ], "template-curly-spacing": "error", "spaced-comment": [ "error", "always" ], "prefer-const" :"warn", "no-octal":"error", "no-octal-escape": "error", "no-new-wrappers": "error", "no-whitespace-before-property": "error", "no-useless-rename": "error", "no-useless-computed-key": "error", "no-trailing-spaces": "error", "strict": ["warn", "function"], "no-shadow-restricted-names": "error", "no-new-object": "error", "no-new-func": "error", "no-multi-spaces": "error", "no-multi-str": "error", "no-new": "error", "no-loop-func" : "warn", "no-lone-blocks": "error", "new-parens": "error", "eol-last": [ "error", "always" ], "dot-location": [ "error", "property" ], "comma-style": [ "error", "last" ], "camelcase": "error", "comma-dangle": [ "error", "never" ], "one-var": [ "error", "never" ], "consistent-this": [ "error", "that" ], "no-constructor-return" : "error", "max-depth": "error", "eqeqeq": "error", "no-class-assign" : "warn", "no-sequences": "error", "no-labels": "error", "no-label-var": "error", "consistent-return": "error", "no-use-before-define": "error", "no-else-return": "error", "no-empty-pattern" : "warn", "no-const-assign": "error", "no-this-before-super": "warn", "no-eq-null" : "warn", "no-dupe-class-members" :"error", "no-undef": "error", "no-unreachable": "error", "no-unused-vars": [ "warn", { "varsIgnorePattern": "EXPORTED_SYMBOLS" } ], "constructor-super": "error", "valid-typeof": "warn", "no-unreachable-loop": "error", "no-promise-executor-return": "error", "no-alert": "warn", "no-magic-numbers": ["warn", { "ignore": [0], "detectObjects": true }], "no-throw-literal": "error", "no-var": "error", "no-confusing-arrow": "error", "no-console": ["warn", { "allow": ["warn", "error"] }], "no-caller": "error", "no-eval": "error", "no-extra-label" :"error", "no-floating-decimal":"error", "no-extend-native": "error", "no-implied-eval": "error", "no-global-assign": "warn", "no-implicit-globals" :"warn", "no-iterator": "error", "no-proto": "error", "no-redeclare" : "error", "no-return-assign": "error", "no-self-compare": "error", "no-self-assign" : "error", "no-script-url": "error", "no-shadow":"warn", "no-useless-catch":"warn", "no-unused-labels":"error", "no-unmodified-loop-condition": "error", "no-useless-concat": "error", "no-useless-escape":"error", "no-useless-call": "error", "no-void": "error", "no-with": "error", "prefer-promise-reject-errors": "error", "prefer-spread": "error", "radix": "error", "no-new-require": "error", "linebreak-style": [ "error", "unix" ], "rest-spread-spacing": ["error", "never"], "no-inline-comments": "error", "no-multi-assign": "error", "no-tabs": "error", "no-useless-constructor": "error", "require-atomic-updates": "warn", "semi": [ "error", "always" ], "no-warning-comments" : "warn", "arrow-body-style": [ "error", "always" ], "arrow-parens": ["error", "always" ], "arrow-spacing": "error", "jsdoc/require-jsdoc": ["error", { "exemptEmptyFunctions":false, "require": { "ClassDeclaration" : true, "ClassExpression" : true, "FunctionDeclaration":true, "MethodDefinition":true } }], "jsdoc/newline-after-description": 0, "jsdoc/valid-types": 1, "jsdoc/no-undefined-types": 0, "jsdoc/require-description-complete-sentence": 0, "jsdoc/check-param-names": 1, "jsdoc/check-tag-names": 1, "jsdoc/check-types": 1, "jsdoc/require-param": 1, "jsdoc/require-param-description": 1, "jsdoc/require-param-name": 1, "jsdoc/require-param-type": 1, "jsdoc/require-returns-description": 1, "jsdoc/require-returns-type": 1, "jsdoc/require-returns-check": 1, "jsdoc/require-returns": ["warn"], "jsdoc/require-description": 1, "jsdoc/require-example": 0, "jsdoc/require-hyphen-before-param-description": 0, //"jsdoc/check-examples": ["warn", {"paddedIndent": 4 }], "jsdoc/check-alignment": 1 //, //"unicorn/prefer-type-error" : "off", //"unicorn/prefer-math-trunc" : "off", //"unicorn/prefer-ternary" : "off", //"unicorn/catch-error-name": "off", //"unicorn/prefer-string-slice" : "off", //"unicorn/explicit-length-check": "off", //"unicorn/no-fn-reference-in-iterator":"off", //"unicorn/no-unused-properties": "error", //"unicorn/no-useless-undefined" : "off", //"unicorn/prefer-optional-catch-binding" : "warn", //"unicorn/prefer-add-event-listener": "warn", //"unicorn/prefer-prototype-methods" : "warn", // Rules which make no sense //"unicorn/prevent-abbreviations" : "off", //"unicorn/empty-brace-spaces" : "off", //"unicorn/no-static-only-class" : "off", //"unicorn/no-lonely-if" : "off", //"unicorn/no-array-for-each" : "off", //"unicorn/filename-case": "off", //"unicorn/no-null": "off", //"unicorn/no-for-loop":"off", //"unicorn/consistent-destructuring" : "off", //"unicorn/numeric-separators-style" : "off", // Rules which ae broken or design flaws which cannot work. //"unicorn/prefer-array-some" : "off", //"unicorn/no-array-callback-reference" : "off", //"unicorn/prefer-dom-node-remove" : "off", //"unicorn/consistent-function-scoping" : "off", //"unicorn/prefer-spread" : "off", //"unicorn/better-regex" : "off", //"unicorn/prefer-module" : "off", // Currently off requires a newer node version //"unicorn/prefer-node-protocol" : "off", //"unicorn/prefer-array-flat" : "off" } }