Lex Berezhny
Lex Berezhny•4mo ago

launch.json for debugging deno next.js in vs code

While following the official next.js in deno tutorial I can't seem to figure out how to run and debug in vs code. Can someone please suggest the contents for launch.json that would allow debugging the next.js app in the tutorial (https://docs.deno.com/examples/next_tutorial/).
3 Replies
Lex Berezhny
Lex BerezhnyOP•4mo ago
looks like it's a known problem, and worse, from this ticket it sounds like when you run next.js with deno it's only the start script that runs in deno but next.js itself runs in node 😲 https://github.com/denoland/deno/issues/28474
GitHub
Next JS with --inspect doesn't work in Deno · Issue #28474 · deno...
deno 2.2.3 (stable, release, aarch64-apple-darwin) v8 13.4.114.11-rusty typescript 5.7.3 It's more an issue in Next rather than in Deno (they rely on NODE_OPTIONS for too much), but maybe you&#...
lcasdev
lcasdev•4mo ago
Are you trying to debug the dev server or a production build? The latter should work if you just pass --inspect when invoking the build output
Lex Berezhny
Lex BerezhnyOP•4mo ago
i gave up on next.js in deno for now and trying deno fresh but having slightly different issue / question, i posted about it in the #fresh channel but to answer your question, i was trying to debug dev server, also i was able to verify that it does in fact start node to run the transform.js, nextjs must have some places hard coded to start node

Did you find this page helpful?