angular-cli icon indicating copy to clipboard operation
angular-cli copied to clipboard

vendor.bundle.js size is around 10 MB

Open jayakrishna-v opened this issue 8 years ago • 24 comments

ng -v 1.5.4 node -v 6.11.2 npm -v 3.10.10

Observed behavior

We have an application with more than 7 modules. When we build this application we are getting vendor.bundle.js file of size 9.95 MB. This will have an impact on performance. Can someone explain the reason fro this and how to reduce the size of build files.

Desired behavior

Expecting lesser size for bundle files

ng build

jayakrishna-v avatar Dec 28 '17 11:12 jayakrishna-v

Hi

I was wondering is there any possible way for me to decrease the size of vendor.js any further? I run this command (as referenced above) ng build --prod --aot --vendor-chunk --common-chunk --delete-output-path --buildOptimizer And the output I get is as follows image

I am using version 8.2.4 of angular

Thanks in advance Damien

damogallagher avatar Aug 31 '19 12:08 damogallagher

utilize children nas suas rotas, refaça toda estrutura usando isso, irá resolver, o seu vendor.js está grande devido a quantidade de rotas iniciais que são carregadas.

lbs-rodrigo avatar Sep 07 '19 14:09 lbs-rodrigo

I already use child routes very everything. I got vendor.js down from 15mb to 3.8

damogallagher avatar Sep 07 '19 19:09 damogallagher

This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.