Skip to content

Commit 9ea923b

Browse files
committed
fix: shim global process
1 parent 91bb19d commit 9ea923b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/build/functions/edge.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -343,8 +343,10 @@ export const createEdgeHandlers = async (ctx: PluginContext) => {
343343
import { init as htmlRewriterInit } from './edge-runtime/vendor/deno.land/x/[email protected]/src/index.ts'
344344
import { handleMiddleware } from './edge-runtime/middleware.ts';
345345
import { registerCJSModules } from "./edge-runtime/lib/cjs.ts";
346+
import process from 'node:process'
346347
import { AsyncLocalStorage } from 'node:async_hooks';
347348
349+
globalThis.process = process
348350
globalThis.AsyncLocalStorage = AsyncLocalStorage;
349351
350352
// needed for path.relative and path.resolve to work

0 commit comments

Comments
 (0)