rspack icon indicating copy to clipboard operation
rspack copied to clipboard

[Regression] remoteEntry.js - performance overhead

Open poseneror opened this issue 1 year ago • 2 comments

Background:

I've made transitioned from react-scripts + craco to rsbuild / rspack. During the transition I was taking different measurements to evaluate the improvements, where I ran into a bundle size regression. We use dynamic remote modules import using module-federation and a version control be service.

Issue:

remoteEntry.js generated with rspack contains meta functions, which increase it's size by a factor:

  • file size [gzipped]: 5kb -> 27kb
  • lines of code: 564 -> 4603

I've been looking for details online, but couldn't find anything useful, not sure if related with MF1.5 or rspack itself. Would appreciate if there's a way to keep to original size of these generated files.

poseneror avatar Aug 04 '24 10:08 poseneror

This issue has been automatically marked as stale because it has not had recent activity. If this issue is still affecting you, please leave any comment (for example, "bump"). We are sorry that we haven't been able to prioritize it yet. If you have any new additional information, please include it with your comment!

stale[bot] avatar Oct 03 '24 12:10 stale[bot]

That seems related to Module Federation, and there's already an issue about it: https://github.com/module-federation/core/issues/2579, and soon a fix with shareable runtime!

markmssd avatar Oct 03 '24 13:10 markmssd

This issue has been automatically marked as stale because it has not had recent activity. If this issue is still affecting you, please leave any comment (for example, "bump"). We are sorry that we haven't been able to prioritize it yet. If you have any new additional information, please include it with your comment!

stale[bot] avatar Dec 07 '24 10:12 stale[bot]

close since it's more like a module-federation issue and it's fixed in module-federation side

hardfist avatar Apr 24 '25 06:04 hardfist