| { |
| "root": true, |
| "ignorePatterns": [ |
| "package.json" |
| ], |
| "overrides": [ |
| { |
| "files": [ |
| "*.ts" |
| ], |
| "parser": "@typescript-eslint/parser", |
| "parserOptions": { |
| "project": [ |
| "**/tsconfig.json" |
| ], |
| "createDefaultProgram": true |
| }, |
| "env": { |
| "browser": true, |
| "es6": true |
| }, |
| "extends": [ |
| "plugin:@angular-eslint/ng-cli-compat", |
| "plugin:@angular-eslint/ng-cli-compat--formatting-add-on", |
| "plugin:@angular-eslint/template/process-inline-templates", |
| "plugin:@typescript-eslint/recommended", |
| "plugin:@typescript-eslint/recommended-requiring-type-checking", |
| "plugin:@microsoft/sdl/required", |
| "plugin:@microsoft/sdl/typescript", |
| "plugin:jsx-a11y/recommended", |
| "plugin:security/recommended", |
| "eslint:recommended", |
| "plugin:node/recommended-module" |
| ], |
| "plugins": [ |
| "eslint-plugin-jest", |
| "eslint-plugin-no-null", |
| "jsdoc", |
| "@microsoft/sdl", |
| "jsx-a11y", |
| "security", |
| "deprecation", |
| "lodash", |
| "prefer-arrow" |
| ], |
| "rules": { |
| "@typescript-eslint/await-thenable": "error", |
| "@typescript-eslint/consistent-type-definitions": "error", |
| "@typescript-eslint/explicit-member-accessibility": [ |
| "off", |
| { |
| "accessibility": "explicit" |
| } |
| ], |
| "@typescript-eslint/no-empty-function": "error", |
| "@typescript-eslint/no-explicit-any": "warn", |
| "@typescript-eslint/no-floating-promises": "warn", |
| "@typescript-eslint/no-for-in-array": "error", |
| "@typescript-eslint/no-inferrable-types": "off", |
| "@typescript-eslint/no-parameter-properties": "error", |
| "@typescript-eslint/no-require-imports": "error", |
| "@typescript-eslint/no-unnecessary-qualifier": "error", |
| "@typescript-eslint/no-var-requires": "error", |
| "@typescript-eslint/promise-function-async": "error", |
| "@typescript-eslint/restrict-plus-operands": "off", |
| "@typescript-eslint/strict-boolean-expressions": "off", |
| "@typescript-eslint/triple-slash-reference": "error", |
| "@typescript-eslint/type-annotation-spacing": "off", |
| "arrow-parens": [ |
| "error", |
| "always" |
| ], |
| "brace-style": [ |
| "off", |
| "off" |
| ], |
| "comma-dangle": "error", |
| "complexity": "error", |
| "default-case": "error", |
| "id-blacklist": "error", |
| "import/no-default-export": "error", |
| "import/order": [ |
| "error", |
| { |
| "alphabetize": { |
| "order": "asc", |
| "caseInsensitive": true |
| } |
| } |
| ], |
| "jest/no-focused-tests": "error", |
| "linebreak-style": "off", |
| "max-classes-per-file": [ |
| "error", |
| 3 |
| ], |
| "max-lines": [ |
| "error", |
| { |
| "max": 1000, |
| "skipComments": true, |
| "skipBlankLines": true |
| } |
| ], |
| "no-constant-condition": "error", |
| "no-control-regex": "error", |
| "no-empty": "error", |
| "no-extra-semi": "error", |
| "no-invalid-regexp": "error", |
| "no-invalid-this": "error", |
| "no-multi-str": "error", |
| "no-multiple-empty-lines": "error", |
| "no-null/no-null": "off", |
| "no-octal": "error", |
| "no-octal-escape": "error", |
| "no-redeclare": "error", |
| "no-regex-spaces": "error", |
| "no-sparse-arrays": "error", |
| "no-void": "error", |
| "space-before-function-paren": "off", |
| "valid-typeof": "error", |
| "require-jsdoc": [ |
| "error", |
| { |
| "require": { |
| "FunctionDeclaration": true, |
| "MethodDefinition": false, |
| "ClassDeclaration": false, |
| "ArrowFunctionExpression": false, |
| "FunctionExpression": false |
| } |
| } |
| ], |
| "max-statements": [ |
| "error", |
| 100 |
| ], |
| "max-len": [ |
| "error", |
| 500 |
| ], |
| "@microsoft/sdl/no-cookies": "error", |
| "@typescript-eslint/no-dynamic-delete": "error", |
| "@microsoft/sdl/no-msapp-exec-unsafe": "error", |
| "@microsoft/sdl/no-winjs-html-unsafe": "error", |
| "constructor-super": "error", |
| "padded-blocks": [ |
| "error", |
| "never" |
| ], |
| "func-style": "error", |
| "@microsoft/sdl/no-insecure-url": [ |
| "error", |
| { |
| "blocklist": [ |
| "^(http|ftp):\\/\\/", |
| "^https:\\/\\/www\\.disallow-example\\.com" |
| ], |
| "exceptions": [ |
| "^http:\\/\\/schemas\\.microsoft\\.com\\/\\/?.*" |
| ] |
| } |
| ], |
| "@microsoft/sdl/no-insecure-random": "off", |
| "@microsoft/sdl/no-inner-html": "error", |
| "@microsoft/sdl/no-html-method": "error", |
| "@typescript-eslint/no-implied-eval": "error", |
| "no-undef-init": "error", |
| "no-with": "error", |
| "security/detect-non-literal-require": "error", |
| "security/detect-possible-timing-attacks": "error", |
| "@typescript-eslint/no-array-constructor": "error", |
| "@typescript-eslint/method-signature-style": "error", |
| "jsx-a11y/anchor-is-valid": [ |
| "off", |
| { |
| "components": [ |
| "Link" |
| ], |
| "specialLink": [ |
| "hrefLeft", |
| "hrefRight" |
| ], |
| "aspects": [ |
| "noHref", |
| "invalidHref", |
| "preferButton" |
| ] |
| } |
| ], |
| "jsx-a11y/aria-unsupported-elements": "error", |
| "jsx-a11y/no-static-element-interactions": "error", |
| "jsx-a11y/alt-text": "error", |
| "jsx-a11y/lang": "error", |
| "jsx-a11y/aria-props": "error", |
| "jsx-a11y/aria-proptypes": "error", |
| "jsx-a11y/aria-role": "error", |
| "jsx-a11y/role-has-required-aria-props": "error", |
| "jsx-a11y/role-supports-aria-props": "error", |
| "jsx-a11y/tabindex-no-positive": "error", |
| "react/jsx-no-target-blank": "error", |
| "@microsoft/sdl/react-iframe-missing-sandbox": "error", |
| "react/no-danger": "error", |
| "react/jsx-curly-spacing": "error", |
| "react/no-unused-state": "error", |
| "lodash/chaining": "error", |
| "@typescript-eslint/ban-types": "off", |
| "deprecation/deprecation": "warn", |
| "@typescript-eslint/naming-convention": [ |
| "warn", |
| { |
| "selector": "variableLike", |
| "format": null |
| } |
| ], |
| "@typescript-eslint/member-ordering": [ |
| "error", |
| { |
| "default": [ |
| "field" |
| ] |
| } |
| ], |
| "@typescript-eslint/no-unsafe-member-access": "off", |
| "@typescript-eslint/no-unused-vars": "off", |
| "no-unused-vars": "off", |
| "no-unsafe-finally": "error", |
| "jsdoc/newline-after-description": [ |
| "warn", |
| "never" |
| ], |
| "@typescript-eslint/unbound-method": "off", |
| "no-underscore-dangle": "off", |
| "no-magic-numbers": "off", |
| "@typescript-eslint/no-magic-numbers": [ |
| "warn", |
| { |
| "ignore": [ |
| -1, |
| 0, |
| 1,2,3 |
| ], |
| "ignoreArrayIndexes": true, |
| "ignoreDefaultValues": true |
| } |
| ], |
| "@typescript-eslint/no-unsafe-assignment": "off", |
| "prefer-arrow/prefer-arrow-functions": [ |
| "warn", |
| { |
| "disallowPrototype": true, |
| "singleReturnOnly": false, |
| "classPropertiesAllowed": false |
| } |
| ], |
| "@angular-eslint/use-lifecycle-interface": "off", |
| "security/detect-non-literal-fs-filename": "error", |
| "@typescript-eslint/no-unsafe-call": "off", |
| "@typescript-eslint/no-unsafe-return": "off", |
| "security/detect-unsafe-regex": "off", |
| "security/detect-non-literal-regexp": "error", |
| "no-console": "error", |
| "sort-keys": "off", |
| "node/no-deprecated-api": [ |
| "warn", |
| { |
| "ignoreModuleItems": [ |
| "util.isNullOrUndefined" |
| ] |
| } |
| ], |
| "node/no-missing-import": [ |
| "off" |
| ], |
| "@typescript-eslint/member-delimiter-style": "off", |
| "node/no-unsupported-features/node-builtins": [ |
| "off" |
| ], |
| "security/detect-object-injection": "warn" |
| } |
| }, |
| { |
| "files": [ |
| "*.html" |
| ], |
| "extends": [ |
| "plugin:@angular-eslint/template/recommended", |
| "plugin:node/recommended-module" |
| ], |
| "rules": {} |
| } |
| ] |
| } |