Workaround swc parsing string as inline sourcemap

This commit is contained in:
TheSparta 2024-04-06 22:36:23 +01:00
parent 3be1768672
commit 198c7a9720

View File

@ -114,8 +114,8 @@ export class ModCompilerService
if (output.sourceMapText)
{
output.outputText = output.outputText.replace(
"//# sourceMappingURL=module.js.map",
`//# sourceMappingURL=${parsedDestPath.base}.map`,
"//# sourceMappingURL\=module.js.map",
`//# sourceMappingURL\=${parsedDestPath.base}.map`,
);
const sourceMap = JSON.parse(output.sourceMapText);