Issue
Can someone explain me exactly the difference between those two flags (optimization
and buildOptimizer
) defined in the build config angular.json
during the build process when I execute ng build
?
The official build documentation isn't clear to me.
Solution
buildOptimizer optimizes the transpilation of TS to JS (remove unused code, add tslib,..) More detailed explanation in the readme of the package https://www.npmjs.com/package/@angular-devkit/build-optimizer
optimization flag I think this one indicates the execution of some Webpack plugins. As in what to do with the JS after the buildOptimizer.
More about optimization flag here
Answered By - Alexander
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.