Skip to content

Commit 2b811db

Browse files
authored
Add key based on request to init fragments (#35)
1 parent 812f03f commit 2b811db

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/transform-async-dependency.cts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,11 @@ export class TransformAsyncDependency
8181
initFragments.push(
8282
// eslint-disable-next-line @typescript-eslint/no-unsafe-call
8383
new InitFragment(
84-
`/* transform async */ var ${dep.#identifier} = ${exportExpr};\n`,
84+
`/* ${dep.type} */ var ${dep.#identifier} = ${exportExpr};\n`,
8585
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
8686
InitFragment.STAGE_ASYNC_BOUNDARY,
87-
-1,
87+
-1, // outside async function wrapper
88+
`${dep.type} ${dep.request}`,
8889
) as (typeof initFragments)[number],
8990
);
9091
}

0 commit comments

Comments
 (0)