From 174966a23905285712a313ce2c867bc03755bcad Mon Sep 17 00:00:00 2001 From: Dmytro Vradii Date: Sun, 20 Oct 2024 17:23:00 +0300 Subject: [PATCH] correct the index file path for SSR builds in the updateIndexHtml util --- libs/native-federation/src/utils/updateIndexHtml.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/native-federation/src/utils/updateIndexHtml.ts b/libs/native-federation/src/utils/updateIndexHtml.ts index d65c31c1..036f7c54 100644 --- a/libs/native-federation/src/utils/updateIndexHtml.ts +++ b/libs/native-federation/src/utils/updateIndexHtml.ts @@ -8,7 +8,7 @@ export function updateIndexHtml( nfOptions: NfBuilderSchema ) { const outputPath = path.join(fedOptions.workspaceRoot, fedOptions.outputPath); - const indexPath = path.join(outputPath, 'index.html'); + const indexPath = path.join(outputPath, nfOptions.ssr ? 'index.csr.html' : 'index.html'); const mainName = fs .readdirSync(outputPath) .find((f) => f.startsWith('main') && f.endsWith('.js'));