Skip to content

Commit

Permalink
Migrate to angular-eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
robisim74 committed May 21, 2021
1 parent cdb7b68 commit 26f319b
Show file tree
Hide file tree
Showing 11 changed files with 1,999 additions and 555 deletions.
51 changes: 51 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{
"root": true,
"ignorePatterns": [
"projects/**/*"
],
"overrides": [
{
"files": [
"*.ts"
],
"parserOptions": {
"project": [
"tsconfig.json",
"e2e/tsconfig.json"
],
"createDefaultProgram": true
},
"extends": [
"plugin:@angular-eslint/recommended",
"plugin:@angular-eslint/template/process-inline-templates"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"prefix": "l10n",
"style": "kebab-case",
"type": "element"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"prefix": "l10n",
"style": "camelCase",
"type": "attribute"
}
]
}
},
{
"files": [
"*.html"
],
"extends": [
"plugin:@angular-eslint/template/recommended"
],
"rules": {}
}
]
}
55 changes: 22 additions & 33 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,11 @@
}
},
"lint": {
"builder": "@angular-devkit/build-angular:tslint",
"builder": "@angular-eslint/builder:lint",
"options": {
"tsConfig": [
"projects/angular-l10n/tsconfig.lib.json",
"projects/angular-l10n/tsconfig.spec.json"
],
"exclude": [
"**/node_modules/**"
"lintFilePatterns": [
"projects/angular-l10n/**/*.ts",
"projects/angular-l10n/**/*.html"
]
}
}
Expand Down Expand Up @@ -113,8 +110,7 @@
},
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"options": {
},
"options": {},
"configurations": {
"production": {
"browserTarget": "angular-l10n-app:build:production"
Expand Down Expand Up @@ -149,15 +145,11 @@
}
},
"lint": {
"builder": "@angular-devkit/build-angular:tslint",
"builder": "@angular-eslint/builder:lint",
"options": {
"tsConfig": [
"projects/angular-l10n-app/tsconfig.app.json",
"projects/angular-l10n-app/tsconfig.spec.json",
"projects/angular-l10n-app/e2e/tsconfig.json"
],
"exclude": [
"**/node_modules/**"
"lintFilePatterns": [
"projects/angular-l10n-app/**/*.ts",
"projects/angular-l10n-app/**/*.html"
]
}
},
Expand Down Expand Up @@ -246,8 +238,7 @@
},
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"options": {
},
"options": {},
"configurations": {
"production": {
"browserTarget": "angular-l10n-app-ssr:build:production"
Expand Down Expand Up @@ -282,16 +273,11 @@
}
},
"lint": {
"builder": "@angular-devkit/build-angular:tslint",
"builder": "@angular-eslint/builder:lint",
"options": {
"tsConfig": [
"projects/angular-l10n-app-ssr/tsconfig.app.json",
"projects/angular-l10n-app-ssr/tsconfig.spec.json",
"projects/angular-l10n-app-ssr/e2e/tsconfig.json",
"projects/angular-l10n-app-ssr/tsconfig.server.json"
],
"exclude": [
"**/node_modules/**"
"lintFilePatterns": [
"projects/angular-l10n-app-ssr/**/*.ts",
"projects/angular-l10n-app-ssr/**/*.html"
]
}
},
Expand Down Expand Up @@ -337,8 +323,7 @@
},
"serve-ssr": {
"builder": "@nguniversal/builders:ssr-dev-server",
"options": {
},
"options": {},
"configurations": {
"production": {
"browserTarget": "angular-l10n-app-ssr:build:production",
Expand Down Expand Up @@ -372,6 +357,10 @@
}
}
}
}},
"defaultProject": "angular-l10n-app"
}
}
},
"defaultProject": "angular-l10n-app",
"cli": {
"defaultCollection": "@angular-eslint/schematics"
}
}
Loading

0 comments on commit 26f319b

Please sign in to comment.