New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
asynchronously load libraries for png and pdf exports #41036
Conversation
@@ -17,6 +14,7 @@ export const saveDashboardPdf = async ( | |||
return; | |||
} | |||
|
|||
const { default: html2canvas } = await import("html2canvas"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: I'd keep import on the top level, but with import()
, so the new chunk will be created automatically and at the same time user will not need to wait for chunk to be downloaded after a click to "download"
actually if you already wait for downloading some big file, chunk loading is not a problem, so please ignore my comment
|
@alxnddr Did you forget to add a milestone to the issue for this PR? When and where should I add a milestone? |
Epic #41032
Description
Reduces the size of the vendor bundle by extracting heavy libraries used for pdf and png exports which should not block the initial app loading.
Before
After
How to verify
vendor
chunk sizeDemo
Screen.Recording.2024-04-04.at.11.09.18.AM.mov