Hi, it is possible somehow optimize `Dashboard` im...
# gooddata-ui
Hi, it is possible somehow optimize
import from the
so it has not over 7mb after minify/bundle? It cause us a lot of trouble recently bundling the app.
We use it like
_import_ { Dashboard } _from_ '@gooddata/sdk-ui-dashboard';
The dashboard is lazily loaded so it do not effect our main bundle but still this single dashboard is bigger than our whole application. 🙂
Hi Jakub, I will notify our engineers about your question. Can you please meanwhile confirm what SDK version are you using?
Thank you. We are currently on the
Are you building your app with webpack or vite? We are facing the same issue and, in the end, we chose to lazily load the Dashboard component. It doesn't decrease the size of what is bundled but it moves out the Dashboard component dependencies from the main bundle to a separate bundle, the latter being only loaded when necessary. Furthermore, when upgrading your application, the "gooddata" bundle should not be invalidated, meaning it can stay in the browser cache longer.
Hi, we use webpack and we lazy load the component, so it is in separate bundle as well.
But still we have some Out of memory issue during building preview on the Vercel. Not in the production build on the Github. I am not even sure it is because of GoodData component, but it looks like that.. it started when we add this dashboard to the app. Previously we used "web-component" but we needed a little bit more control so we switched to the react component.
Our app is quite large (or I thought it was), but this single dashboard is even bigger 🙂 we use it only in "readOnly" mode.
Hi all, Radek here 🙂 I'll check this with the devs and let you know if there's a better way around this!
👀 1
Okay, got all the information together - essentially, the Dashboard component is probably the largest one we have, and any changes to its size are unlikely to come soon - sorry I couldn't bring happier news! 😅
Thank you for information. We will have to deal with it.