File tree 1 file changed +10
-10
lines changed
docs/documentation/stories
1 file changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -41,29 +41,29 @@ export const environment = {
41
41
```
42
42
43
43
44
- Update ` . angular-cli .json` by adding the new environment the existing environments object:
44
+ Update ` angular.json ` to include an hmr environment as explained [ here ] ( ./application- environments) and add a configuration within serve to enable hmr.
45
45
46
46
``` json
47
- "environmentSource " : " environments/environment.ts " ,
48
- "environments " : {
49
- "dev" : " environments/environment.ts " ,
50
- "hmr" : " environments/environment.hmr.ts " ,
51
- "prod" : " environments/environment.prod.ts "
52
- },
47
+ "serve " : {
48
+ "configuration " : {
49
+ ...
50
+ "hmr" : true
51
+ }
52
+ }
53
53
```
54
54
55
- Run ` ng serve ` with the flag ` --hmr -e= hmr ` to enable hmr and select the new environment:
55
+ Run ` ng serve ` with the flag ` --configuration hmr ` to enable hmr and select the new environment:
56
56
57
57
``` bash
58
- ng serve --hmr -e= hmr
58
+ ng serve --configuration hmr
59
59
```
60
60
61
61
Create a shortcut for this by updating ` package.json ` and adding an entry to the script object:
62
62
63
63
``` json
64
64
"scripts" : {
65
65
...
66
- "hmr" : " ng serve --hmr -e= hmr"
66
+ "hmr" : " ng serve --configuration hmr"
67
67
}
68
68
```
69
69
You can’t perform that action at this time.
0 commit comments