node/doc/api
Joyee Cheung 6183a759d7
vm: make vm.Module.evaluate() conditionally synchronous
- Make sure that the vm.Module.evaluate() method is conditionally
  synchronous based on the specification. Previously, the returned
  promise is unconditionally pending (even for synthetic modules and
  source text modules without top-level await) instead of immediately
  fulfilled, making it harder to debug as it deviates from the
  specified behavior.
- Clarify the synchronicity of this method in the documentation
- Add more tests for the synchronicity of this method.

PR-URL: https://github.com/nodejs/node/pull/60205
Refs: https://github.com/nodejs/node/issues/59656
Refs: https://github.com/nodejs/node/issues/37648
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
2025-11-07 18:11:33 +01:00
..
addons.md doc: fix c++ addon hello world sample 2024-12-09 17:43:50 +00:00
assert.md 2025-09-25, Version 24.9.0 (Current) 2025-09-24 09:06:46 +02:00
async_context.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
async_hooks.md doc,tools: enforce use of node: prefix 2024-07-21 15:44:27 +00:00
buffer.md doc: fix blob.bytes() heading level 2025-11-07 18:11:30 +01:00
child_process.md doc: fix typo on child_process.md 2025-10-06 16:27:11 +02:00
cli.md doc: add --heap-snapshot-on-oom to useful v8 flag 2025-11-07 18:11:30 +01:00
cluster.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
console.md 2025-10-08, Version 24.10.0 (Current) 2025-10-08 10:24:11 -03:00
corepack.md doc: clarify future Corepack removal in v25+ 2025-05-08 09:59:50 +02:00
crypto.md doc,crypto: reorder ML-KEM in the asymmetric key types table 2025-10-06 16:24:00 +02:00
debugger.md inspector: introduce the --inspect-wait flag 2024-05-11 18:48:30 +00:00
deprecations.md doc: add automated migration info to deprecations 2025-10-06 22:41:29 -03:00
dgram.md 2025-06-09, Version 24.2.0 (Current) 2025-06-09 15:36:15 +02:00
diagnostics_channel.md 2025-09-10, Version 24.8.0 (Current) 2025-09-10 15:38:56 +02:00
dns.md doc: format safely for doc-kit 2025-08-08 11:56:49 +02:00
documentation.md doc: clarify release candidate stability index 2025-08-12 09:19:59 -03:00
domain.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
embedding.md doc: improve c++ embedder API doc 2024-11-01 03:43:53 +00:00
environment_variables.md doc: mark .env files support as stable 2025-10-06 16:26:10 +02:00
errors.md doc: disambiguate top-level worker_threads module exports 2025-11-07 18:11:27 +01:00
esm.md doc: rephrase dynamic import() description 2025-09-12 16:39:34 +02:00
events.md doc: format safely for doc-kit 2025-08-08 11:56:49 +02:00
fs.md doc: fix filehandle.read typo 2025-09-04 10:15:12 +02:00
globals.md doc: disambiguate top-level worker_threads module exports 2025-11-07 18:11:27 +01:00
http2.md doc: improve documentation for raw headers in HTTP/2 APIs 2025-09-04 10:15:14 +02:00
http.md 2025-09-25, Version 24.9.0 (Current) 2025-09-24 09:06:46 +02:00
https.md 2025-07-31, Version 24.5.0 (Current) 2025-07-31 10:26:53 +02:00
index.md doc: add new environment variables doc page 2025-07-21 10:59:02 +02:00
inspector.md 2025-08-27, Version 24.7.0 (Current) 2025-08-27 11:27:15 +02:00
intl.md
module.md doc: format safely for doc-kit 2025-08-08 11:56:49 +02:00
modules.md doc: format safely for doc-kit 2025-08-08 11:56:49 +02:00
n-api.md 2025-09-25, Version 24.9.0 (Current) 2025-09-24 09:06:46 +02:00
net.md 2025-07-31, Version 24.5.0 (Current) 2025-07-31 10:26:53 +02:00
os.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
packages.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
path.md 2025-09-10, Version 24.8.0 (Current) 2025-09-10 15:38:56 +02:00
perf_hooks.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
permissions.md doc: remove broken link to permission model source code 2025-07-08 11:44:43 -03:00
process.md doc: disambiguate top-level worker_threads module exports 2025-11-07 18:11:27 +01:00
punycode.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
querystring.md
quic.md doc: fix quic session instance typo 2025-09-04 10:15:13 +02:00
readline.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
repl.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
report.md 2025-01-07, Version 22.13.0 'Jod' (LTS) 2025-01-07 14:36:47 -05:00
single-executable-applications.md 2025-09-10, Version 24.8.0 (Current) 2025-09-10 15:38:56 +02:00
sqlite.md doc: createSQLTagStore -> createTagStore 2025-11-07 18:11:28 +01:00
stream.md lib: fix isReadable and isWritable return type value 2025-09-09 08:34:18 +02:00
string_decoder.md doc: add esm examples to node:string_decoder 2024-10-26 20:36:25 +00:00
synopsis.md
test.md 2025-08-27, Version 24.7.0 (Current) 2025-08-27 11:27:15 +02:00
timers.md 2025-06-09, Version 24.2.0 (Current) 2025-06-09 15:36:15 +02:00
tls.md doc: update OpenSSL default security level to 2 2025-09-09 08:40:51 +02:00
tracing.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
tty.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
typescript.md doc: update "Type stripping in dependencies" section 2025-09-04 10:15:18 +02:00
url.md doc: improve code snippet alternative of url.parse() using WHATWG URL 2025-11-07 18:11:28 +01:00
util.md 2025-10-08, Version 24.10.0 (Current) 2025-10-08 10:24:11 -03:00
v8.md 2025-09-25, Version 24.9.0 (Current) 2025-09-24 09:06:46 +02:00
vm.md vm: make vm.Module.evaluate() conditionally synchronous 2025-11-07 18:11:33 +01:00
wasi.md doc: fix typed list formatting 2025-07-17 16:57:14 +02:00
webcrypto.md doc,crypto: update subtle.generateKey and subtle.importKey 2025-09-24 09:03:34 +02:00
webstreams.md 2025-08-27, Version 24.7.0 (Current) 2025-08-27 11:27:15 +02:00
worker_threads.md doc: disambiguate top-level worker_threads module exports 2025-11-07 18:11:27 +01:00
zlib.md doc: add missing Zstd strategy constants 2025-08-21 19:01:11 +02:00