diff --git a/.changeset/honest-coins-ring.md b/.changeset/honest-coins-ring.md new file mode 100644 index 000000000..cb1aaca9f --- /dev/null +++ b/.changeset/honest-coins-ring.md @@ -0,0 +1,5 @@ +--- +"@callstack/repack": patch +--- + +Fix ValidationError in ModuleFederationPlugin caused by reactNativeDeepImports prop diff --git a/packages/repack/src/webpack/plugins/ModuleFederationPlugin.ts b/packages/repack/src/webpack/plugins/ModuleFederationPlugin.ts index d5998e8f6..b2359a683 100644 --- a/packages/repack/src/webpack/plugins/ModuleFederationPlugin.ts +++ b/packages/repack/src/webpack/plugins/ModuleFederationPlugin.ts @@ -244,7 +244,7 @@ export class ModuleFederationPlugin implements WebpackPlugin { ); new container.ModuleFederationPlugin({ - ...this.config, + exposes: this.config.exposes, filename: this.config.filename ?? this.config.exposes ? `${this.config.name}.container.bundle` @@ -256,8 +256,12 @@ export class ModuleFederationPlugin implements WebpackPlugin { ...this.config.library, } : undefined, + name: this.config.name, shared: sharedDependencies, + shareScope: this.config.shareScope, remotes, + remoteType: this.config.remoteType, + runtime: this.config.runtime, }).apply(compiler); } }