Skip to content

Commit

Permalink
fix(angular): Module federation with Crystal enabled. (#22224)
Browse files Browse the repository at this point in the history
(cherry picked from commit 381a36d)
  • Loading branch information
ndcunningham authored and FrozenPandaz committed Mar 8, 2024
1 parent 6790a2e commit 208d496
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/angular/src/utils/mf/with-module-federation-ssr.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ import { getModuleFederationConfig } from './utils';
export async function withModuleFederationForSSR(
options: ModuleFederationConfig
) {
if (global.NX_GRAPH_CREATION) {
return (config) => config;
}
const { sharedLibraries, sharedDependencies, mappedRemotes } =
await getModuleFederationConfig(options, {
isServer: true,
Expand Down
3 changes: 3 additions & 0 deletions packages/angular/src/utils/mf/with-module-federation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ import { getModuleFederationConfig } from './utils';
import ModuleFederationPlugin = require('webpack/lib/container/ModuleFederationPlugin');

export async function withModuleFederation(options: ModuleFederationConfig) {
if (global.NX_GRAPH_CREATION) {
return (config) => config;
}
const { sharedLibraries, sharedDependencies, mappedRemotes } =
await getModuleFederationConfig(options);

Expand Down

0 comments on commit 208d496

Please sign in to comment.