Running nodejs (cjs) libs with node_modules deps using deno-runtime
#23468
-
Hi, so I 've been trying to use deno-runtime to run some js code from rust, the js code has some node_modules deps as well as nodejs builtins and is in cjs format, so I have a few questions about this that someone may help me with: do I need to pull deno-std from remote as a side-module when I instantiated the so I think Im pretty close, I was able to work it out with esm format, by pulling in the Im pretty new to deno, so I would appreciate if anyone can help me. thanks |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
You shouldn't use
And then you can assign it to |
Beta Was this translation helpful? Give feedback.
That's correct.
That code is only required when an ESM module tries to
import
a CJS module. If you want to execute only CJS then it s…