Child Process
Node.js child_process module — spawn child processes.
Provides synchronous and asynchronous methods for creating child processes. Sync methods (execSync, execFileSync, spawnSync) block the event loop and are commonly used in build scripts and CLI tooling. Async methods (exec, execFile, spawn, fork) return ChildProcess EventEmitter objects with streaming stdout/stderr via the event loop.
Module:node:child_process
Support: Experimental
Since: 1.1.0
Docs: Node.js Docs
7 members: 7 undocumented
Static Methods
Dictionary SpawnSyncResult
Result object returned by spawnSync().
Since: 1.1.0 Docs: Node.js Docs7 members: 7 undocumented
Properties
Process ID of the child.
Process ID of the child.
Stdout output (Buffer or string depending on encoding option).
Stderr output (Buffer or string depending on encoding option).
Exit code of the child process, or null if terminated by signal.
Stderr output (Buffer or string depending on encoding option).
Error object if the child failed to spawn.
---