'ng build called twice consecutively without any changes should not perform operations
I am using Angular CLI 13.3.9 on Windows and created a new default application running ng new SampleApp.
When running ng build in the created SampleApp-folder the command takes around 15sec for the first run. Running the same command again, manually via entering ng build again, without any kind of changes it takes around 3sec. Any further runs will also take around 3sec.
Is there any way to configure ng build to run a change detection before it starts to bundle the application, copy assets and generating the Index html without any changes?
Expected behavior would be that it returns instantly with stating that nothing changed and output files are up to date.
Solution 1:[1]
There is a feature of angular after version 8 and it is called differential loading
The two build you are seeing is because of different browser targets.
You can find more information about that here
https://medium.com/@auth0/a-guide-to-angular-8s-differential-loading-ad08278a7d17
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Jalpesh Vadgama |
