Skip to content

Commit c61c24e

Browse files
committed
avoid preprocess()ing modules with ids like rollupPluginBabelHelpers.js
1 parent e4d0877 commit c61c24e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/processScript/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ export async function processScript(code: string, {
260260
{
261261
name: `hackmud-script-manager`,
262262
async transform(code, id) {
263-
if (!id.includes(`/node_modules/`))
263+
if (id.startsWith(`/`) && !id.includes(`/node_modules/`))
264264
return (await preprocess(code, { uniqueId })).code
265265

266266
let program!: NodePath<Program>

0 commit comments

Comments
 (0)