File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
packages/cloudflare/src/api Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -69,10 +69,10 @@ async function getCloudflareContextInNextDev<
69
69
} ;
70
70
71
71
if ( ! global [ cloudflareContextInNextDevSymbol ] ) {
72
- // Note: we need to add the webpackIgnore comment to the dynamic import because
73
- // the next dev server transpiled modules on the fly but we don't want it to try
74
- // to also transpile the wrangler code
75
- const { getPlatformProxy } = await import ( /* webpackIgnore: true */ "wrangler" ) ;
72
+ // Note: we never want wrangler to be bundled in the Next.js app, that's why the import below looks like it does
73
+ const { getPlatformProxy } = await import (
74
+ /* webpackIgnore: true */ ` ${ "__wrangler" . replaceAll ( "_" , "" ) } `
75
+ ) ;
76
76
const { env, cf, ctx } = await getPlatformProxy ( ) ;
77
77
global [ cloudflareContextInNextDevSymbol ] = {
78
78
env,
You can’t perform that action at this time.
0 commit comments