[ACS-4837] eslint spellcheck support (#3072)

* eslint spellcheck support

* restore node memory settings for linting
This commit is contained in:
Denys Vuika 2023-03-17 05:31:23 -04:00 committed by GitHub
parent 36c5c39311
commit 86c0bbb998
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 507 additions and 1483 deletions

View File

@ -14,13 +14,15 @@
"extends": [
"plugin:@angular-eslint/ng-cli-compat",
"plugin:@angular-eslint/ng-cli-compat--formatting-add-on",
"plugin:@angular-eslint/template/process-inline-templates"
"plugin:@angular-eslint/template/process-inline-templates",
"plugin:@cspell/recommended"
],
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn",
"rxjs",
"unicorn",
"prettier",
"ban"
"ban",
"@cspell"
],
"rules": {
"ban/ban": [

View File

@ -15,100 +15,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": [
"app",
"aca",
"adf"
],
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": "aca",
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error",
"@angular-eslint/template/eqeqeq": "error"
}
}
]

View File

@ -14,100 +14,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": [
"app",
"aca",
"adf"
],
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": "aca",
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error",
"@angular-eslint/template/eqeqeq": "error"
}
}
]

View File

@ -1,11 +0,0 @@
{
"extends": "./tsconfig.e2e.json",
"compilerOptions": {
"noEmit": true,
"noUnusedLocals": true,
"noImplicitAny": false,
"esModuleInterop": true,
"allowJs": true,
"allowSyntheticDefaultImports": true
}
}

1093
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -17,11 +17,9 @@
"build-libs": "ng build aca-shared && ng build adf-office-services-ext && ng build aca-about && ng build aca-viewer && ng build aca-preview && ng build aca-folder-rules && ng build aca-content",
"test": "ng test",
"test:ci": "ng test adf-office-services-ext && ng test content-ce --code-coverage",
"lint": "NODE_OPTIONS=--max_old_space_size=4096 ng lint && npm run spellcheck && npm run e2e.typecheck",
"lint": "NODE_OPTIONS=--max_old_space_size=4096 ng lint",
"update-webdriver": "./scripts/update-webdriver.sh",
"e2e.typecheck": "tsc -p ./e2e/tsconfig.e2e.typecheck.json",
"e2e": "npm run update-webdriver && protractor $SUITE",
"spellcheck": "cspell '{src,e2e,projects}/**/*.ts'",
"inspect.bundle": "ng build content-ce --configuration production --stats-json && npx webpack-bundle-analyzer dist/content-ce/stats.json",
"prepare": "husky install",
"stylelint": "stylelint \"{app,projects}/**/*.scss\""
@ -75,6 +73,7 @@
"@angular/cli": "14.1.2",
"@angular/compiler-cli": "14.1.2",
"@angular/language-service": "14.1.2",
"@cspell/eslint-plugin": "^6.30.0",
"@playwright/test": "^1.31.2",
"@types/event-emitter": "^0.3.3",
"@types/jasmine": "~3.6.0",
@ -86,7 +85,6 @@
"@typescript-eslint/parser": "^5.48.2",
"ajv-cli": "^4.2.0",
"commander": "^6.1.0",
"cspell": "^6.23.0",
"cypress": "^12.6.0",
"dotenv": "8.2.0",
"dotenv-expand": "^5.1.0",

View File

@ -15,106 +15,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error",
"@angular-eslint/template/eqeqeq": "error"
}
}
]

View File

@ -15,106 +15,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error",
"@angular-eslint/template/eqeqeq": "error"
}
}
]

View File

@ -15,105 +15,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error"
}
}
]

View File

@ -15,106 +15,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error",
"@angular-eslint/template/eqeqeq": "error"
}
}
]

View File

@ -15,104 +15,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": [
"aca",
"adf",
"app"
],
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": [
"aca",
"adf",
"app"
],
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error",
"@angular-eslint/template/eqeqeq": "error"
}
}
]

View File

@ -15,106 +15,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": [
"lib",
"aca",
"app",
"adf"
],
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error",
"@angular-eslint/template/eqeqeq": "error"
}
}
]

View File

@ -15,96 +15,7 @@
],
"createDefaultProgram": true
},
"plugins": [
"eslint-plugin-rxjs",
"eslint-plugin-unicorn"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": "lib",
"style": "kebab-case"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": "lib",
"style": "camelCase"
}
],
"@angular-eslint/no-host-metadata-property": "off",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": [
"off",
{
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"off",
{
"multiline": {
"delimiter": "none",
"requireLast": true
},
"singleline": {
"delimiter": "semi",
"requireLast": false
}
}
],
"@typescript-eslint/semi": [
"off",
null
],
"@typescript-eslint/type-annotation-spacing": "off",
"arrow-parens": [
"off",
"always"
],
"brace-style": [
"off",
"off"
],
"eol-last": "off",
"id-blacklist": "off",
"id-match": "off",
"linebreak-style": "off",
"max-len": "off",
"new-parens": "off",
"newline-per-chained-call": "off",
"no-duplicate-imports": "error",
"no-extra-semi": "off",
"no-irregular-whitespace": "off",
"no-return-await": "error",
"no-underscore-dangle": "off",
"quote-props": "off",
"rxjs/no-create": "error",
"rxjs/no-subject-unsubscribe": "error",
"rxjs/no-subject-value": "error",
"rxjs/no-unsafe-takeuntil": "error",
"space-before-function-paren": "off",
"space-in-parens": [
"off",
"never"
],
"unicorn/filename-case": "error"
}
},
{
"files": [
"*.html"
],
"rules": {
"@angular-eslint/template/no-autofocus": "error",
"@angular-eslint/template/no-negated-async": "off",
"@angular-eslint/template/no-positive-tabindex": "error",
"@angular-eslint/template/eqeqeq": "error"
}
}
]