Skip to content

Commit 30473f9

Browse files
committed
fix(@angular/build): normalize paths during module resolution in Vite
Before this update, the importer path was not normalized, causing mismatches during SSR on Windows.
1 parent e6d5c7e commit 30473f9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/angular/build/src/tools/vite/angular-memory-plugin.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ export function createAngularMemoryPlugin(options: AngularMemoryPluginOptions):
5555
return source;
5656
}
5757

58-
if (importer && source[0] === '.' && importer.startsWith(virtualProjectRoot)) {
58+
if (importer && source[0] === '.' && normalizePath(importer).startsWith(virtualProjectRoot)) {
5959
// Remove query if present
6060
const [importerFile] = importer.split('?', 1);
6161

0 commit comments

Comments
 (0)