问题
I am developing a web application with Angular 6. I have an Ag-grid enterprise edition. Ag-grid documentation says, that we have to import all ag-grid-angular, ag-grid-community, and ag-grid-enterprise to work with Ag-grid enterprise.
After compiling, the total main bundle size crosses 1.5 MB. In that ag-grid-community is 694KB and ag-grid-enterprise is 230 KB:
Is this the normal behavior of Ag-grid?
I am using Ag-grid version 19.0.0 and the following command for building:
ng build --prod --aot --build-optimizer --vendor-chunk=true
回答1:
This is something that we know and we have in our backlog
Project structure improvements AG-1329 Reduce grid bundle size (via tree shaking)
You can see our pipeline here:
https://www.ag-grid.com/ag-grid-pipeline/
Note that we don't have any plans to do any improvements any time soon given its comlexity, but we are hoping to eventually be able to provide with a small bundle
I would recommend that if you are a customer, that you contact ag-grid support directly for more information
Hope this helps
来源:https://stackoverflow.com/questions/52827942/ag-grid-bundle-size-is-too-big