From b006bda2f2b6010e204dc49d28cfacb3fbe9d1ad Mon Sep 17 00:00:00 2001 From: Luke Romanowicz Date: Wed, 16 Dec 2020 11:31:08 +0100 Subject: [PATCH] fix: support symbolic links in building docs dist --- src/node/build/render.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/node/build/render.ts b/src/node/build/render.ts index 3883e38f..06b22dbf 100644 --- a/src/node/build/render.ts +++ b/src/node/build/render.ts @@ -89,7 +89,7 @@ function resolvePageImports( // find the page's js chunk and inject script tags for its imports so that // they are start fetching as early as possible - const srcPath = path.resolve(config.root, page) + const srcPath = fs.realpathSync(path.resolve(config.root, page)) const pageChunk = result.assets.find( (chunk) => chunk.type === 'chunk' && chunk.facadeModuleId === srcPath ) as OutputChunk