Skip to content

Commit af0a677

Browse files
committed
ref/ eslint conf
1 parent 1fb08a7 commit af0a677

File tree

2 files changed

+28
-54
lines changed

2 files changed

+28
-54
lines changed

Diff for: .eslintrc.json

+17-49
Original file line numberDiff line numberDiff line change
@@ -1,81 +1,49 @@
11
{
2-
"env": {
3-
"browser": true,
4-
"node": true,
5-
"es6": true,
6-
"es2017": true
7-
},
2+
"root": true,
3+
"ignorePatterns": [
4+
"projects/**/*"
5+
],
86
"overrides": [
97
{
108
"files": [
119
"*.ts"
1210
],
13-
"extends": [
14-
"eslint:recommended",
15-
"plugin:@typescript-eslint/eslint-recommended",
16-
"plugin:@typescript-eslint/recommended",
17-
"plugin:@typescript-eslint/recommended-requiring-type-checking"
18-
],
19-
"parser": "@typescript-eslint/parser",
2011
"parserOptions": {
21-
"ecmaVersion": 10,
2212
"project": [
2313
"./tsconfig.serve.json",
2414
"./src/tsconfig.app.json",
2515
"./src/tsconfig.spec.json",
2616
"./e2e/tsconfig.e2e.json"
2717
],
28-
"sourceType": "module",
29-
"ecmaFeatures": {
30-
"modules": true
31-
}
18+
"createDefaultProgram": true
3219
},
33-
"plugins": [
34-
"@typescript-eslint",
35-
"@angular-eslint/eslint-plugin"
20+
"extends": [
21+
"plugin:@angular-eslint/recommended",
22+
"plugin:@angular-eslint/template/process-inline-templates"
3623
],
3724
"rules": {
38-
"@typescript-eslint/indent": [
25+
"@angular-eslint/directive-selector": 0,
26+
"@angular-eslint/component-selector": [
3927
"error",
40-
2,
4128
{
42-
"SwitchCase": 1,
43-
"CallExpression": {
44-
"arguments": "first"
45-
},
46-
"FunctionExpression": {
47-
"parameters": "first"
48-
},
49-
"FunctionDeclaration": {
50-
"parameters": "first"
51-
}
29+
"type": "element",
30+
"prefix": "app",
31+
"style": "kebab-case"
5232
}
53-
],
54-
"@typescript-eslint/no-empty-function": 0,
55-
"@typescript-eslint/no-explicit-any": 0,
56-
"@typescript-eslint/no-var-requires": 0,
57-
"@typescript-eslint/no-unsafe-call": 0,
58-
"@typescript-eslint/no-unsafe-member-access": 0,
59-
"@typescript-eslint/no-unsafe-assignment": 0,
60-
"@typescript-eslint/no-unsafe-return": 0,
61-
"@typescript-eslint/no-floating-promises": 0,
62-
"@typescript-eslint/semi": "error",
63-
"@angular-eslint/use-injectable-provided-in": "error",
64-
"@angular-eslint/no-attribute-decorator": "error"
33+
]
6534
}
6635
},
6736
{
6837
"files": [
6938
"*.component.html"
7039
],
71-
"parser": "@angular-eslint/template-parser",
72-
"plugins": [
73-
"@angular-eslint/template"
40+
"extends": [
41+
"plugin:@angular-eslint/template/recommended"
7442
],
7543
"rules": {
7644
"@angular-eslint/template/banana-in-box": "error",
7745
"@angular-eslint/template/no-negated-async": "error"
7846
}
7947
}
8048
]
81-
}
49+
}

Diff for: src/tsconfig.app.json

+11-5
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,24 @@
66
"baseUrl": "",
77
"types": []
88
},
9-
"include": [
9+
"files": [
1010
"main.ts",
11-
"polyfills.ts",
12-
"app/**/*.ts",
13-
"environments/**/*.ts"
11+
"polyfills.ts"
12+
],
13+
"include": [
14+
"**/*.d.ts"
1415
],
1516
"exclude": [
1617
"**/*.spec.ts"
1718
],
1819
"angularCompilerOptions": {
20+
"strictTemplates": true,
1921
"fullTemplateTypeCheck": true,
22+
"annotateForClosureCompiler": true,
2023
"strictInjectionParameters": true,
21-
"preserveWhitespaces": true
24+
"skipTemplateCodegen": false,
25+
"preserveWhitespaces": true,
26+
"skipMetadataEmit": false,
27+
"disableTypeScriptVersionCheck": true
2228
}
2329
}

0 commit comments

Comments
 (0)