Skip to content

Commit cd97134

Browse files
committedJun 27, 2024·
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. (cherry picked from commit 30473f9)
1 parent 12b96d1 commit cd97134

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

Diff for: ‎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)
Please sign in to comment.