Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(linter): use standard angular linter (#1276)
- Loading branch information
1 parent
6d8e1a3
commit e7251d1
Showing
78 changed files
with
463 additions
and
1,125 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
{ | ||
"extends": ".eslintrc.json", | ||
"ignorePatterns": [ | ||
"!**/*" | ||
], | ||
"overrides": [ | ||
{ | ||
"files": [ | ||
"*.ts" | ||
], | ||
"extends": [ | ||
"eslint:recommended", | ||
"plugin:@typescript-eslint/recommended", | ||
"plugin:@angular-eslint/recommended", | ||
"plugin:@angular-eslint/template/process-inline-templates" | ||
], | ||
"rules": { | ||
"@typescript-eslint/adjacent-overload-signatures": "warn", // TODO: remove this warning when refactoring unit tests. | ||
"no-useless-escape": "warn", // TODO: remove this warning when refactoring unit tests. | ||
"no-case-declarations": "warn", // TODO: remove this warning when refactoring unit tests. | ||
"@angular-eslint/directive-selector": [ | ||
"error", | ||
{ | ||
"type": "attribute", | ||
"prefix": "app", | ||
"style": "camelCase" | ||
} | ||
], | ||
"@angular-eslint/component-selector": [ | ||
"error", | ||
{ | ||
"type": "element", | ||
"prefix": "app", | ||
"style": "kebab-case" | ||
} | ||
] | ||
} | ||
}, | ||
{ // TODO: remove these .spec.ts eslint rules when refactoring unit tests | ||
"files": [ | ||
"*.spec.ts" | ||
], | ||
"rules": { | ||
"no-undef": "off", | ||
"@typescript-eslint/no-empty-function": "off", | ||
"@nrwl/nx/enforce-module-boundaries": "off", | ||
"@angular-eslint/no-empty-lifecycle-method": "off", | ||
"@angular-eslint/component-selector": "off" | ||
} | ||
}, | ||
{ | ||
"files": [ | ||
"*.html" | ||
], | ||
"extends": [ | ||
"plugin:@angular-eslint/template/recommended", | ||
"plugin:@angular-eslint/template/accessibility" | ||
], | ||
"rules": { // TODO: remove all those warnings when refactoring unit tests. | ||
"@angular-eslint/template/interactive-supports-focus": "warn", | ||
"@angular-eslint/template/mouse-events-have-key-events": "warn", | ||
"@angular-eslint/template/click-events-have-key-events": "warn", | ||
"@angular-eslint/template/label-has-associated-control": "warn" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,53 +1,3 @@ | ||
{ | ||
"extends": ["../../.eslintrc.json"], | ||
"ignorePatterns": ["!**/*"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts"], | ||
"rules": { | ||
"@nrwl/nx/enforce-module-boundaries": [ | ||
"error", | ||
{ | ||
"allow": ["@dsp-app/**"] | ||
} | ||
], | ||
"@angular-eslint/directive-selector": [ | ||
"warn", | ||
{ | ||
"type": "attribute", | ||
"prefix": "app", | ||
"style": "camelCase" | ||
} | ||
], | ||
"@angular-eslint/component-selector": [ | ||
"warn", | ||
{ | ||
"type": "element", | ||
"prefix": "dsp-app", | ||
"style": "kebab-case" | ||
} | ||
], | ||
"@angular-eslint/no-empty-lifecycle-method": "warn", | ||
"@angular-eslint/no-output-native": "warn", | ||
"@typescript-eslint/no-empty-function": "off", | ||
"@typescript-eslint/adjacent-overload-signatures": "warn", | ||
"@typescript-eslint/prefer-as-const": "warn", | ||
"@typescript-eslint/no-unused-vars": "warn", | ||
"@typescript-eslint/no-explicit-any": "warn", | ||
"no-useless-escape": "warn", | ||
"no-case-declarations": "warn", | ||
"no-prototype-builtins": "warn", | ||
"no-constant-condition": "warn" | ||
}, | ||
"extends": [ | ||
"plugin:@nrwl/nx/angular", | ||
"plugin:@angular-eslint/template/process-inline-templates" | ||
] | ||
}, | ||
{ | ||
"files": ["*.html"], | ||
"extends": ["plugin:@nrwl/nx/angular-template"], | ||
"rules": {} | ||
} | ||
] | ||
"extends": ["../../.eslintrc-angular.json"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,53 +1,3 @@ | ||
{ | ||
"extends": ["../../.eslintrc.json"], | ||
"ignorePatterns": ["!**/*"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts"], | ||
"rules": { | ||
"@nrwl/nx/enforce-module-boundaries": [ | ||
"error", | ||
{ | ||
"allow": ["@dsp-app/**"] | ||
} | ||
], | ||
"@angular-eslint/directive-selector": [ | ||
"warn", | ||
{ | ||
"type": "attribute", | ||
"prefix": "app", | ||
"style": "camelCase" | ||
} | ||
], | ||
"@angular-eslint/component-selector": [ | ||
"warn", | ||
{ | ||
"type": "element", | ||
"prefix": "app", | ||
"style": "kebab-case" | ||
} | ||
], | ||
"@angular-eslint/no-empty-lifecycle-method": "warn", | ||
"@angular-eslint/no-output-native": "warn", | ||
"@typescript-eslint/no-empty-function": "off", | ||
"@typescript-eslint/adjacent-overload-signatures": "warn", | ||
"@typescript-eslint/prefer-as-const": "warn", | ||
"@typescript-eslint/no-unused-vars": "warn", | ||
"@typescript-eslint/no-explicit-any": "warn", | ||
"no-useless-escape": "warn", | ||
"no-case-declarations": "warn", | ||
"no-prototype-builtins": "warn", | ||
"no-constant-condition": "warn" | ||
}, | ||
"extends": [ | ||
"plugin:@nrwl/nx/angular", | ||
"plugin:@angular-eslint/template/process-inline-templates" | ||
] | ||
}, | ||
{ | ||
"files": ["*.html"], | ||
"extends": ["plugin:@nrwl/nx/angular-template"], | ||
"rules": {} | ||
} | ||
] | ||
"extends": "../../.eslintrc-angular.json" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.