You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently node federation is implemented as a runtimePlugin, but relies on webpack APIs to hook into chunk loading. This makes Node federation tightly coupled with webpack.
Suggested solution
Introducing new APIs and runtime hooks to tap into chunk loading makes Node federation completely free of webpack.
API and Hooks for chunk loading
loadChunk()
loadChunk API will be used to load any chunk exposed by a remote.
loadChunk will use the appropriate loader to load the chunk
import for ESM
require for CJS
require (from requirejs) for AMD
System.import for SystemJS
NOTE: Using the appropriate loader to handle chunk loading is already taken care by the bundler during output generation phase
resolveChunk()
Allows for manual resolution of chunk load requests.
This runtime hook will be called before a chunk is resolved
Similar to resolveShare, one can provide an explicit resolver which resolves to a module
Currently node federation is implemented as a runtimePlugin, but relies on webpack APIs to hook into chunk loading. This makes Node federation tightly coupled with webpack.
Suggested solution
Introducing new APIs and runtime hooks to tap into chunk loading makes Node federation completely free of webpack.
API and Hooks for chunk loading
import
for ESMrequire
for CJSrequire
(from requirejs) for AMDSystem.import
for SystemJSAlternative
No response
Additional context
No response
Validations
The text was updated successfully, but these errors were encountered: