Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
114 commits
Select commit Hold shift + click to select a range
c190e28
feat: support async startup promise across formats
ScriptedAlchemy Oct 16, 2025
40c571a
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Oct 16, 2025
241a46e
fix(runtime): avoid duplicate export for mf async startup
ScriptedAlchemy Oct 16, 2025
b22849c
fix(runtime): gate async startup and reuse default export
ScriptedAlchemy Oct 16, 2025
2ef62db
chore(binding): sync wasi generated exports
ScriptedAlchemy Oct 16, 2025
8b99fdd
chore: drop webpack hot-case bundles
ScriptedAlchemy Oct 17, 2025
36cd349
fix(runtime): adjust async startup promise flow
ScriptedAlchemy Oct 17, 2025
3a3b9c1
fix(runtime): prevent async startup wrapper for simple entries withou…
ScriptedAlchemy Oct 17, 2025
8ecf6e4
test: fix container tests and sync WASI bindings
ScriptedAlchemy Oct 18, 2025
be3302e
fix(runtime): preserve async chunk loading for non-MF projects
ScriptedAlchemy Oct 19, 2025
38b4c77
fix(runtime): await async chunk loaders
ScriptedAlchemy Oct 19, 2025
a8ce32c
chore: merge origin main
ScriptedAlchemy Oct 19, 2025
463e19b
fix(runtime): ensure async loaders await dependencies
ScriptedAlchemy Oct 19, 2025
d1c8a51
refactor(runtime): tidy async startup hash update
ScriptedAlchemy Oct 19, 2025
4cc4f4e
fix(runtime): gate mf async startup behind experiment
ScriptedAlchemy Oct 20, 2025
30b5d94
fix: honor explicit mfAsyncStartup for containers
ScriptedAlchemy Oct 20, 2025
a70265d
fix(mf): include runtime handlers in enhanced mode
ScriptedAlchemy Oct 20, 2025
23c719c
fix(mf): remove async startup wrapping from containers
ScriptedAlchemy Oct 20, 2025
d67e097
refactor(mf): improve HoistContainerReferencesPlugin runtime chunk ma…
ScriptedAlchemy Oct 20, 2025
5b23c61
fix(mf): restore runtime chunk detection in HoistContainerReferencesP…
ScriptedAlchemy Oct 21, 2025
0a9103f
fix(mf): keep bundler runtime helper in runtime chunk
ScriptedAlchemy Oct 21, 2025
7946cb0
test: update mf fixtures and watch expectations
ScriptedAlchemy Oct 21, 2025
d9882dd
Merge branch 'main' into feature/async-startup-runtime-promise
ScriptedAlchemy Oct 21, 2025
6d29968
fix: re-add mfAsyncStartup experiment after main merge
ScriptedAlchemy Oct 21, 2025
8990fac
fix: ignore ustr-fxhash transitive dependency in cargo-shear
ScriptedAlchemy Oct 21, 2025
1a9e85e
fix(mf): gate async wrapper by chunk_needs_mf_async_startup
ScriptedAlchemy Oct 21, 2025
d57e766
fix: update API extractor output to remove mfAsyncStartup references
ScriptedAlchemy Oct 21, 2025
6093ae3
test: update test snapshots and expectations after mf async startup fix
ScriptedAlchemy Oct 21, 2025
708b67c
fix: suppress dead code warnings for plugin hook structs and methods
ScriptedAlchemy Oct 21, 2025
dab2dc1
test: update Rust defaults snapshot for mf_async_startup field
ScriptedAlchemy Oct 21, 2025
f5a1dbf
fix: use module-level allow(dead_code) for plugin hook system
ScriptedAlchemy Oct 21, 2025
94711b2
fix(mf): re-enable hoist container hoisting
ScriptedAlchemy Oct 21, 2025
1e50a14
fix(binding): add mf async startup bindings
ScriptedAlchemy Oct 22, 2025
7796253
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Oct 22, 2025
7fcf21e
perf(mf): skip hoist when federation deps missing
ScriptedAlchemy Oct 22, 2025
aee5d59
Remove library test directory (doesn't exist on main)
ScriptedAlchemy Oct 22, 2025
1582cbe
Remove split-chunks snapshot to match main branch
ScriptedAlchemy Oct 22, 2025
36da492
fix(tests): restore test files from main to fix defaults tests
ScriptedAlchemy Oct 22, 2025
3b6d207
fix(tests): update base.js snapshot to include mfAsyncStartup
ScriptedAlchemy Oct 22, 2025
fb2d020
refactor(mf): improve HoistContainerReferencesPlugin code quality
ScriptedAlchemy Oct 22, 2025
df7151b
revert: unrelated CSS test package.json formatting changes
ScriptedAlchemy Oct 22, 2025
fd00613
fix(mf): remove unused ustr dependency from Cargo.toml
ScriptedAlchemy Oct 22, 2025
0623ed8
chore: update Cargo.lock after removing ustr dependency
ScriptedAlchemy Oct 22, 2025
8994f30
fix: gate all MF async startup logic on experiment flag
ScriptedAlchemy Oct 22, 2025
28eba04
fix: properly gate MF async startup to preserve main branch behavior
ScriptedAlchemy Oct 22, 2025
29ac7d4
fix: update hot snapshot for MF share-plugin test
ScriptedAlchemy Oct 22, 2025
b3b3c5d
fix: suppress false positive 'this' unused warning in BuildInfo
ScriptedAlchemy Oct 22, 2025
8c3fcc4
chore: increase lint warning threshold to accommodate CI environment
ScriptedAlchemy Oct 22, 2025
4d77e07
Revert "chore: increase lint warning threshold to accommodate CI envi…
ScriptedAlchemy Oct 22, 2025
00cbb22
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Oct 22, 2025
52fb979
fix(rspack): make build info inspect serializable
ScriptedAlchemy Oct 22, 2025
31da1bb
fix(incremental): avoid repeat full-hash warnings
ScriptedAlchemy Oct 22, 2025
3ba4253
test(container): align async startup expectations
ScriptedAlchemy Oct 22, 2025
fbd55b0
test(container): handle remote share versions
ScriptedAlchemy Oct 22, 2025
b5c3d9c
test(container): normalize async startup expectations
ScriptedAlchemy Oct 23, 2025
beddcde
fix(container): gate EntryFederationRuntimeModule by async startup flag
ScriptedAlchemy Oct 23, 2025
e030641
fix(mf): skip federation startup call in async mode
ScriptedAlchemy Oct 23, 2025
b7118da
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Oct 23, 2025
420b7f6
fix(mf): guard embed runtime plugin behind async startup
ScriptedAlchemy Oct 23, 2025
3ebd6f3
fix(mf): ensure backwards compatibility for async startup feature
ScriptedAlchemy Oct 23, 2025
b395434
fix(tests): silence hot css logging and align externals
ScriptedAlchemy Oct 23, 2025
a34b4aa
fix(mf): gate all async startup changes behind experiment flag
ScriptedAlchemy Oct 24, 2025
1315c0a
fix(mf): restrict async startup to MF-participating chunks only (P0)
ScriptedAlchemy Oct 24, 2025
c3e1054
fix(tests): align library test configs with main branch
ScriptedAlchemy Oct 24, 2025
ed1c31a
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Oct 24, 2025
3112141
Merge branch 'main' into feature/async-startup-runtime-promise
ScriptedAlchemy Oct 24, 2025
deca562
fix(ir): minimal async startup gating
ScriptedAlchemy Oct 25, 2025
5b238ab
fix(runtime): restore sync startup when mf async disabled
ScriptedAlchemy Oct 27, 2025
df01379
test(stats): restore snapshot baselines
ScriptedAlchemy Oct 27, 2025
7c7e021
fix(runtime): restore startup plugin wiring for async
ScriptedAlchemy Oct 27, 2025
e8a04f9
fix(resolver): avoid sharing alias caches across compilers
ScriptedAlchemy Oct 27, 2025
57c5905
Revert unrelated changes
ScriptedAlchemy Oct 27, 2025
9094974
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Oct 27, 2025
ba884df
Merge branch 'main' into feature/async-startup-runtime-promise
ScriptedAlchemy Oct 27, 2025
bcde5e7
chore: revert HotSnapshot hottest test
ScriptedAlchemy Oct 27, 2025
ef5fe7f
chore: revert BuildInfo overrides
ScriptedAlchemy Oct 27, 2025
780c4ed
chore: revert module federation default runtime
ScriptedAlchemy Oct 27, 2025
c0e6cfa
refactor: parse startup exports with swc
ScriptedAlchemy Oct 27, 2025
7aded25
revert: drop async startup changes
ScriptedAlchemy Oct 27, 2025
d767978
chore: remove mf entry runtime shim
ScriptedAlchemy Oct 27, 2025
b452da3
chore: sync runtime cargo manifest
ScriptedAlchemy Oct 27, 2025
f8ec4f3
chore: snapshot current work
ScriptedAlchemy Oct 28, 2025
0f2d5f4
chore: snapshot current work
ScriptedAlchemy Oct 28, 2025
c7f5d5c
test: update default options snapshot
ScriptedAlchemy Oct 28, 2025
ab27f3a
chore: remove investigation markdown files
ScriptedAlchemy Oct 28, 2025
762e0ef
Merge branch 'main' into feature/async-startup-runtime-promise
ScriptedAlchemy Oct 28, 2025
a0926e8
chore: remove comprehensive research and analysis files related to ge…
ScriptedAlchemy Oct 28, 2025
689dab5
refactor(tests): simplify container test cases and update rspack conf…
ScriptedAlchemy Oct 28, 2025
5686be5
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Oct 28, 2025
8016dd8
fix: correct container entry chunk handling for non-async startup
ScriptedAlchemy Oct 28, 2025
8ff2703
fix: resolve test failures for async startup and ESM output
ScriptedAlchemy Oct 28, 2025
023c30b
wip: add Promise-based wrapper for async federation startup (CJS work…
ScriptedAlchemy Oct 28, 2025
8a5a4b2
feat: implement async federation startup for entry chunks (1635/1636 …
ScriptedAlchemy Oct 28, 2025
b1f5b57
feat: implement ESM async startup with Promise.resolve().then() pattern
ScriptedAlchemy Oct 28, 2025
fb3b268
refine container entry detection for async startup
ScriptedAlchemy Oct 29, 2025
d30b7d9
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Oct 29, 2025
44e0920
fix: align mf async startup defaults
ScriptedAlchemy Oct 29, 2025
9e622ce
Merge branch 'main' into feature/async-startup-runtime-promise
ScriptedAlchemy Oct 29, 2025
776c5a5
fix: avoid string conversion on source value
ScriptedAlchemy Oct 29, 2025
0ab50b4
test: update esm output snapshots
ScriptedAlchemy Oct 29, 2025
f3b0a0f
feat: support mf async startup in esm runtime
ScriptedAlchemy Oct 29, 2025
a6b8659
Revert "test: update esm output snapshots"
ScriptedAlchemy Oct 30, 2025
bb1f22a
fix: gate mf async startup runtime by experiment
ScriptedAlchemy Oct 30, 2025
1190bd9
chore: restore esm snapshot baselines
ScriptedAlchemy Oct 30, 2025
8aadb28
fix: gate mf async bootstrap and preserve imports
ScriptedAlchemy Oct 30, 2025
aacf919
fix: export EmbedFederationRuntimeModule to fix cacheable deserializa…
ScriptedAlchemy Oct 31, 2025
0be6e50
fix: restore accidentally removed exports from WASI binding files
ScriptedAlchemy Oct 31, 2025
9914305
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Nov 1, 2025
2c08ac8
test: update stats exports snapshot
ScriptedAlchemy Nov 1, 2025
553915a
test: update stats exports snapshot for macOS build
ScriptedAlchemy Nov 2, 2025
ba6e99b
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Nov 2, 2025
45b3afc
Merge remote-tracking branch 'origin/main' into feature/async-startup…
ScriptedAlchemy Nov 5, 2025
17ec896
Merge branch 'main' into feature/async-startup-runtime-promise
ScriptedAlchemy Nov 5, 2025
5037973
chore: format examples/basic config
ScriptedAlchemy Nov 5, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions crates/node_binding/napi-binding.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2123,6 +2123,7 @@ inlineEnum: boolean
typeReexportsPresence: boolean
lazyBarrel: boolean
deferImport: boolean
mfAsyncStartup: boolean
}

export interface RawExperimentSnapshotOptions {
Expand Down
6 changes: 5 additions & 1 deletion crates/rspack/src/builder/builder_context.rs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,11 @@ impl BuilderContext {
plugins.push(rspack_plugin_runtime::ModuleChunkFormatPlugin::default().boxed());
}
BuiltinPluginOptions::EnableChunkLoadingPlugin(chunk_loading_type) => {
rspack_plugin_runtime::enable_chunk_loading_plugin(chunk_loading_type, &mut plugins);
rspack_plugin_runtime::enable_chunk_loading_plugin(
chunk_loading_type,
compiler_options.experiments.mf_async_startup,
&mut plugins,
);
}
BuiltinPluginOptions::EnableWasmLoadingPlugin(wasm_loading_type) => {
plugins.push(rspack_plugin_wasm::enable_wasm_loading_plugin(
Expand Down
1 change: 1 addition & 0 deletions crates/rspack/src/builder/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3803,6 +3803,7 @@ impl ExperimentsBuilder {
type_reexports_presence: false,
lazy_barrel: false,
defer_import: false,
mf_async_startup: false,
})
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1524,6 +1524,7 @@ CompilerOptions {
type_reexports_presence: false,
lazy_barrel: false,
defer_import: false,
mf_async_startup: false,
},
node: Some(
NodeOption {
Expand Down
3 changes: 2 additions & 1 deletion crates/rspack_binding_api/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -219,8 +219,9 @@ impl JsCompiler {
let js_cleanup_plugin = JsCleanupPlugin::new(tsfn);
plugins.push(js_cleanup_plugin.boxed());

let mf_async_startup = options.experiments.mf_async_startup;
for bp in builtin_plugins {
bp.append_to(env, &mut this, &mut plugins)?;
bp.append_to(env, &mut this, mf_async_startup, &mut plugins)?;
}

let pnp = options.resolve.pnp.unwrap_or(false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,7 @@ impl<'a> BuiltinPlugin<'a> {
self,
env: Env,
compiler_object: &mut Object,
mf_async_startup: bool,
plugins: &mut Vec<BoxPlugin>,
) -> napi::Result<()> {
let name = match self.name {
Expand Down Expand Up @@ -389,7 +390,11 @@ impl<'a> BuiltinPlugin<'a> {
BuiltinPluginName::EnableChunkLoadingPlugin => {
let chunk_loading_type = downcast_into::<String>(self.options)
.map_err(|report| napi::Error::from_reason(report.to_string()))?;
enable_chunk_loading_plugin(chunk_loading_type.as_str().into(), plugins);
enable_chunk_loading_plugin(
chunk_loading_type.as_str().into(),
mf_async_startup,
plugins,
);
}
BuiltinPluginName::EnableLibraryPlugin => {
let library_type = downcast_into::<String>(self.options)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ pub struct RawExperiments {
pub type_reexports_presence: bool,
pub lazy_barrel: bool,
pub defer_import: bool,
pub mf_async_startup: bool,
}

impl From<RawExperiments> for Experiments {
Expand All @@ -53,6 +54,7 @@ impl From<RawExperiments> for Experiments {
type_reexports_presence: value.type_reexports_presence,
lazy_barrel: value.lazy_barrel,
defer_import: value.defer_import,
mf_async_startup: value.mf_async_startup,
}
}
}
1 change: 1 addition & 0 deletions crates/rspack_core/src/options/experiments/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ pub struct Experiments {
pub type_reexports_presence: bool,
pub lazy_barrel: bool,
pub defer_import: bool,
pub mf_async_startup: bool,
}

#[allow(clippy::empty_structs_with_brackets)]
Expand Down
6 changes: 6 additions & 0 deletions crates/rspack_plugin_esm_library/src/link.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1733,6 +1733,12 @@ impl EsmLibraryPlugin {
continue;
};

if !matches!(
dep.dependency_type(),
DependencyType::EsmImport | DependencyType::EsmExportImport
) {
continue;
}
let Some(conn) = module_graph.connection_by_dependency_id(dep_id) else {
continue;
};
Expand Down
Loading
Loading