adobe / aem-core-cif-components

A set of configurations and components to get you started with AEM Commerce development
Apache License 2.0
102 stars 80 forks source link

Reduce Bundle Size? #1004

Open MichaelHeinzman opened 3 months ago

MichaelHeinzman commented 3 months ago

Description & Motivation

I'm just wondering if there's anyway to reduce the bundle size so that when utilizing certain components it doesn't increase the file size by 1mb each time I import @adobe/aem-core-cif-react-components. When I comment out these imports and use custom coded ones that do the same thing, the performance in lighthouse significantly increases, from around 34 to around 48. I'm not sure if there's a way to only import the necessary code instead of the whole bundle.