mirror of
https://github.com/Kir-Antipov/mc-publish.git
synced 2024-11-24 09:21:04 -05:00
240 lines
7.8 KiB
Text
240 lines
7.8 KiB
Text
{
|
|
"root": true,
|
|
"parser": "@typescript-eslint/parser",
|
|
"plugins": ["@typescript-eslint"],
|
|
"env": {
|
|
"node": true
|
|
},
|
|
"extends": [
|
|
"eslint:recommended",
|
|
"plugin:@typescript-eslint/recommended"
|
|
],
|
|
"rules": {
|
|
"array-callback-return": "error",
|
|
"no-constant-binary-expression": "error",
|
|
"no-constant-condition": ["error", { "checkLoops": false }],
|
|
"no-constructor-return": "error",
|
|
"no-duplicate-imports": "error",
|
|
"no-new-native-nonconstructor": "error",
|
|
"no-promise-executor-return": "error",
|
|
"no-self-compare": "error",
|
|
"no-template-curly-in-string": "warn",
|
|
"no-unmodified-loop-condition": "warn",
|
|
"no-unreachable-loop": "warn",
|
|
"no-unused-private-class-members": "error",
|
|
"@typescript-eslint/no-unused-vars": ["error", {
|
|
"varsIgnorePattern": "^_",
|
|
"argsIgnorePattern": "^_"
|
|
}],
|
|
"no-use-before-define": "off",
|
|
"require-atomic-updates": "off",
|
|
|
|
"accessor-pairs": "error",
|
|
"arrow-body-style": "off",
|
|
"block-scoped-var": "error",
|
|
"camelcase": "off",
|
|
"capitalized-comments": "off",
|
|
"class-methods-use-this": "off",
|
|
"complexity": ["error", 32],
|
|
"consistent-return": "error",
|
|
"consistent-this": "error",
|
|
"curly": "error",
|
|
"default-case": "error",
|
|
"default-case-last": "error",
|
|
"default-param-last": "error",
|
|
"dot-notation": "off",
|
|
"eqeqeq": "error",
|
|
"func-name-matching": "off",
|
|
"func-names": "off",
|
|
"func-style": ["error", "declaration", { "allowArrowFunctions": true }],
|
|
"grouped-accessor-pairs": "error",
|
|
"guard-for-in": "error",
|
|
"id-denylist": "off",
|
|
"id-length": "off",
|
|
"id-match": "off",
|
|
"init-declarations": "off",
|
|
"logical-assignment-operators": "error",
|
|
"max-classes-per-file": ["error", 2],
|
|
"max-depth": "error",
|
|
"max-lines": "off",
|
|
"max-lines-per-function": "off",
|
|
"max-nested-callbacks": "error",
|
|
"max-params": ["error", 6],
|
|
"max-statements": "off",
|
|
"multiline-comment-style": ["error", "separate-lines"],
|
|
"new-cap": ["error", { "capIsNewExceptionPattern": "[^\\p{Ll}]*$" }],
|
|
"no-alert": "error",
|
|
"no-array-constructor": "error",
|
|
"no-bitwise": "off",
|
|
"no-caller": "error",
|
|
"no-case-declarations": "off",
|
|
"no-confusing-arrow": "off",
|
|
"no-console": "error",
|
|
"no-continue": "off",
|
|
"no-div-regex": "error",
|
|
"no-else-return": "error",
|
|
"no-empty": "error",
|
|
"@typescript-eslint/no-empty-function": ["error", { "allow": ["arrowFunctions"] }],
|
|
"no-empty-static-block": "error",
|
|
"no-eq-null": "error",
|
|
"no-eval": "error",
|
|
"no-extend-native": "error",
|
|
"no-extra-bind": "error",
|
|
"no-extra-label": "error",
|
|
"no-floating-decimal": "error",
|
|
"no-implicit-coercion": "off",
|
|
"no-implicit-globals": "error",
|
|
"no-implied-eval": "error",
|
|
"no-inline-comments": "error",
|
|
"no-invalid-this": "error",
|
|
"no-iterator": "error",
|
|
"no-label-var": "error",
|
|
"no-labels": "error",
|
|
"no-lone-blocks": "error",
|
|
"no-lonely-if": "error",
|
|
"no-loop-func": "error",
|
|
"no-magic-numbers": "off",
|
|
"no-mixed-operators": "off",
|
|
"no-multi-assign": "error",
|
|
"no-multi-str": "error",
|
|
"no-negated-condition": "error",
|
|
"no-nested-ternary": "off",
|
|
"no-new": "error",
|
|
"no-new-func": "error",
|
|
"no-new-object": "error",
|
|
"no-new-wrappers": "error",
|
|
"no-octal-escape": "error",
|
|
"no-param-reassign": "off",
|
|
"no-plusplus": "off",
|
|
"no-proto": "error",
|
|
"no-restricted-exports": "off",
|
|
"no-restricted-globals": "off",
|
|
"no-restricted-imports": ["error", {
|
|
"name": "node-fetch",
|
|
"message": "Please use `import { fetch } from \"@/utils/net\";` instead."
|
|
}],
|
|
"no-restricted-properties": "off",
|
|
"no-restricted-syntax": "off",
|
|
"no-return-assign": "error",
|
|
"no-return-await": "off",
|
|
"no-script-url": "error",
|
|
"no-sequences": "error",
|
|
"no-shadow": "off",
|
|
"no-ternary": "off",
|
|
"no-throw-literal": "error",
|
|
"no-undef-init": "off",
|
|
"no-undefined": "off",
|
|
"no-underscore-dangle": "off",
|
|
"no-unneeded-ternary": "error",
|
|
"no-unused-expressions": "error",
|
|
"no-useless-call": "error",
|
|
"no-useless-computed-key": "error",
|
|
"no-useless-concat": "error",
|
|
"no-useless-constructor": "off",
|
|
"no-useless-rename": "error",
|
|
"no-useless-return": "error",
|
|
"no-var": "error",
|
|
"no-void": "error",
|
|
"no-warning-comments": "error",
|
|
"object-shorthand": "error",
|
|
"one-var": ["error", "never"],
|
|
"one-var-declaration-per-line": "error",
|
|
"operator-assignment": "error",
|
|
"prefer-arrow-callback": "error",
|
|
"prefer-const": ["error", { "destructuring": "all" }],
|
|
"prefer-destructuring": "off",
|
|
"prefer-exponentiation-operator": "error",
|
|
"prefer-named-capture-group": "off",
|
|
"prefer-numeric-literals": "error",
|
|
"prefer-object-has-own": "error",
|
|
"prefer-object-spread": "error",
|
|
"prefer-promise-reject-errors": "error",
|
|
"prefer-regex-literals": "off",
|
|
"prefer-rest-params": "error",
|
|
"prefer-spread": "error",
|
|
"prefer-template": "error",
|
|
"quote-props": ["error", "consistent-as-needed"],
|
|
"radix": "off",
|
|
"require-await": "error",
|
|
"require-unicode-regexp": "off",
|
|
"sort-imports": "off",
|
|
"sort-keys": "off",
|
|
"sort-var": "off",
|
|
"spaced-comment": "error",
|
|
"strict": ["error", "never"],
|
|
"symbol-description": "error",
|
|
"vars-on-top": "error",
|
|
"yoda": "error",
|
|
|
|
"array-bracket-newline": "off",
|
|
"array-bracket-spacing": "error",
|
|
"array-element-newline": "off",
|
|
"arrow-parens": ["error", "as-needed"],
|
|
"arrow-spacing": "error",
|
|
"block-spacing": "error",
|
|
"brace-style": "error",
|
|
"comma-dangle": ["error", "always-multiline"],
|
|
"comma-spacing": "error",
|
|
"comma-style": "error",
|
|
"computed-property-spacing": "error",
|
|
"dot-location": ["error", "property"],
|
|
"eol-last": "error",
|
|
"func-call-spacing": "error",
|
|
"function-call-argument-newline": "off",
|
|
"function-paren-newline": "off",
|
|
"generator-star-spacing": ["error", { "before": false, "after": true, "method": "neither" }],
|
|
"implicit-arrow-linebreak": "off",
|
|
"indent": "off",
|
|
"jsx-quotes": "error",
|
|
"key-spacing": "error",
|
|
"keyword-spacing": "error",
|
|
"line-comment-position": "error",
|
|
"linebreak-style": "off",
|
|
"@typescript-eslint/lines-around-comment": ["error", {
|
|
"allowClassStart": true,
|
|
"allowInterfaceStart": true,
|
|
"allowTypeStart": true,
|
|
"allowEnumStart": true,
|
|
"allowModuleStart": true,
|
|
"allowBlockStart": true,
|
|
"allowObjectStart": true,
|
|
"allowArrayStart": true
|
|
}],
|
|
"lines-between-class-members": "error",
|
|
"max-len": "off",
|
|
"max-statements-per-line": "error",
|
|
"multiline-ternary": "off",
|
|
"new-parens": "error",
|
|
"newline-per-chained-call": "off",
|
|
"no-extra-parens": "off",
|
|
"no-multi-spaces": "error",
|
|
"no-multiple-empty-lines": "off",
|
|
"no-tabs": "error",
|
|
"no-trailing-spaces": "error",
|
|
"no-whitespace-before-property": "error",
|
|
"nonblock-statement-body-position": "error",
|
|
"object-curly-newline": "off",
|
|
"object-curly-spacing": ["error", "always"],
|
|
"object-property-newline": "off",
|
|
"operator-linebreak": "off",
|
|
"padded-blocks": "off",
|
|
"padding-line-between-statements": "off",
|
|
"quotes": "error",
|
|
"rest-spread-spacing": "error",
|
|
"semi": "error",
|
|
"semi-spacing": "error",
|
|
"semi-style": "error",
|
|
"space-before-blocks": "error",
|
|
"space-before-function-paren": ["error", { "anonymous": "never", "named": "never", "asyncArrow": "always" }],
|
|
"space-in-parens": "error",
|
|
"space-infix-ops": "error",
|
|
"space-unary-ops": "error",
|
|
"switch-colon-spacing": "error",
|
|
"template-curly-spacing": "error",
|
|
"template-tag-spacing": "error",
|
|
"unicode-bom": "error",
|
|
"wrap-iife": ["error", "inside"],
|
|
"wrap-regex": "off",
|
|
"yield-star-spacing": "error"
|
|
}
|
|
}
|