I am working on a big project and it takes to much time to run that project, so while googling I got an idea of hot module replacement, but I don't know how to implement it so please help me how to implement HRM in angular 9
Asked
Active
Viewed 522 times
1 Answers
0
It is not a part of angular 9, it is released with Angular 11 by default. You should upgrade the angular version and ready to use it.
Main reason: Earlier even making a smaller change trigger angular dev server to re-compile and process all the files again which takes time to re-render and re-paint everything with HMR it will be quick. It takes a lot of time based on your system configuration.
HMR is not a angular feature, but it is a webpack feature
and bundled in the angular 11 version by default. HMR is to update the application modules without reloading and repainting everything.
How to use it:
ng serve --hmr
You can check here for more details.

Apoorva Chikara
- 8,277
- 3
- 20
- 35
-
If the answer helps , you can accept and upvote it. You will be rewarded for that too! – Apoorva Chikara May 26 '21 at 11:43