Skip to content

Commit

Permalink
chore: fix web-worker runner options
Browse files Browse the repository at this point in the history
  • Loading branch information
sheremet-va committed May 10, 2023
1 parent 5cc8e09 commit 2d1e452
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/web-worker/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ export function createMessageEvent(data: any, transferOrOptions: StructuredSeria
}

export function getRunnerOptions(): any {
const { config, ctx, rpc, mockMap, moduleCache } = getWorkerState()
const state = getWorkerState()
const { config, ctx, rpc, mockMap, moduleCache } = state

return {
fetchModule(id: string) {
Expand All @@ -75,5 +76,6 @@ export function getRunnerOptions(): any {
interopDefault: config.deps.interopDefault ?? true,
root: config.root,
base: config.base,
state,
}
}

0 comments on commit 2d1e452

Please sign in to comment.