Skip to content

Commit

Permalink
fix(react): fix skipRemotes in moduleFederationDevServer (#14172)
Browse files Browse the repository at this point in the history
Co-authored-by: rsmaciel <rsmaciel@rederecord.com.br>
  • Loading branch information
Ronaldo-Maciel and rsmaciel committed Feb 22, 2023
1 parent bacd875 commit ba73775
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,10 @@ export default async function* moduleFederationDevServer(
}

const remotesToSkip = new Set(options.skipRemotes ?? []);
const knownRemotes = (moduleFederationConfig.remotes ?? []).filter(
(r) => !remotesToSkip.has(r)
);
const knownRemotes = (moduleFederationConfig.remotes ?? []).filter((r) => {
const validRemote = Array.isArray(r) ? r[0] : r;
return !remotesToSkip.has(validRemote);
});

const devServeApps = !options.devRemotes
? []
Expand Down

0 comments on commit ba73775

Please sign in to comment.