Skip to content

Commit 04f805b

Browse files
committed
在 angular.json 中設定不產生 spec 檔
1 parent ed9198f commit 04f805b

File tree

1 file changed

+28
-8
lines changed

1 file changed

+28
-8
lines changed

angular.json

+28-8
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,29 @@
88
"sourceRoot": "src",
99
"projectType": "application",
1010
"prefix": "app",
11-
"schematics": {},
11+
"schematics": {
12+
"@schematics/angular:class": {
13+
"spec": false
14+
},
15+
"@schematics/angular:component": {
16+
"spec": false
17+
},
18+
"@schematics/angular:directive": {
19+
"spec": false
20+
},
21+
"@schematics/angular:guard": {
22+
"spec": false
23+
},
24+
"@schematics/angular:module": {
25+
"spec": false
26+
},
27+
"@schematics/angular:pipe": {
28+
"spec": false
29+
},
30+
"@schematics/angular:service": {
31+
"spec": false
32+
}
33+
},
1234
"architect": {
1335
"build": {
1436
"builder": "@angular-devkit/build-angular:browser",
@@ -29,12 +51,10 @@
2951
},
3052
"configurations": {
3153
"production": {
32-
"fileReplacements": [
33-
{
34-
"replace": "src/environments/environment.ts",
35-
"with": "src/environments/environment.prod.ts"
36-
}
37-
],
54+
"fileReplacements": [{
55+
"replace": "src/environments/environment.ts",
56+
"with": "src/environments/environment.prod.ts"
57+
}],
3858
"optimization": true,
3959
"outputHashing": "all",
4060
"sourceMap": false,
@@ -119,4 +139,4 @@
119139
}
120140
},
121141
"defaultProject": "realworld-basic"
122-
}
142+
}

0 commit comments

Comments
 (0)