angular - Why apps built with Angular2 are so heavy? -


recently planned revamp our existing web-app built in jmvc. , decided go angular-2.

and test load size, did following:

ng new test123 cd test123 ng build -prod 

and deployed dist folder content on apache , showed 1.0mb transferred.

my entire jmvc application, business logic hardly 1.2mb when loaded in browser.

what can decrease size of angular-2 app after deployment?

enter image description here

as per comments, ng2 team working on reducing size of framework nearing release.

prior this, following typical http conventions minimising js size main thing, i've found webpacks optimisations heavily reduce size of generated js substantially.

enter image description here

thats 313kb entire angular2 code base entire app includes inline html , styling (i'm not sure result hello world example though).

the webpack plugins can use

webpack.optimize.occurenceorderplugin(true) webpack.optimize.uglifyjsplugin() webpack.optimize.dedupeplugin() 

hope helps!


Comments

Popular posts from this blog

wordpress - (T_ENDFOREACH) php error -

Export Excel workseet into txt file using vba - (text and numbers with formulas) -

Using django-mptt to get only the categories that have items -