Skip to content

Commit

Permalink
fix: the result value of resolve add a namespace when processing a '@…
Browse files Browse the repository at this point in the history
…' in filter,fix vitejs#3532
  • Loading branch information
ygj6 committed May 25, 2021
1 parent 496e26e commit 6da781f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/vite/src/node/optimizer/scan.ts
Original file line number Diff line number Diff line change
Expand Up @@ -288,9 +288,11 @@ function esbuildScanPlugin(
}
return externalUnlessEntry({ path: id })
} else {
const namespace = htmlTypesRE.test(resolved) ? 'html' : undefined
// linked package, keep crawling
return {
path: path.resolve(resolved)
path: path.resolve(resolved),
namespace
}
}
} else {
Expand Down

0 comments on commit 6da781f

Please sign in to comment.