fix: don't handle module ID that begin with \0 (#530)

This commit is contained in:
Justin Carrus 2024-06-15 07:03:45 -07:00 committed by GitHub
parent b3185d7fc5
commit 73dfee5a4f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -87,6 +87,12 @@ export default function assetPlugin(): Plugin {
return wasmHelperCode
}
if (id.startsWith('\0')) {
// Rollup convention, this id should be handled by the
// plugin that marked it with \0
return
}
const assetResolved = resolveAsset(id)
if (!assetResolved) {
return