fix: don't handle file ids that begin with a null byte

This commit is contained in:
Justin Carrus 2024-06-10 08:19:52 -07:00
parent 1838bdbf3e
commit ac894731f7

View File

@ -87,6 +87,12 @@ export default function assetPlugin(): Plugin {
return wasmHelperCode 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) const assetResolved = resolveAsset(id)
if (!assetResolved) { if (!assetResolved) {
return return