deno
e183faf9 - fix(node_shim): emit --require/--import; test node --require/-p via task

Commit
149 days ago
fix(node_shim): emit --require/--import; test node --require/-p via task node_shim's translate_to_deno_args parsed --require/-r/--import into preload_cjs_modules/preload_esm_modules but never emitted them as Deno --require/--import flags, so delegating NodeCommand to node_shim would drop preloads. Emit them in both the run and eval translation paths (the proper shared home, benefiting child_process too), and carry them through the node -e/-p temp-file path. Add a PATH-cleared lifecycle-script spec covering 'node --require ./helper.cjs main.cjs' (proves the preload actually runs, vs a node fallback) and 'node -p', plus node_shim unit tests for the new emission.
Author
Committer
Parents
Loading