Skip to content

Instantly share code, notes, and snippets.

@ndelangen
Last active January 2, 2017 14:40
Show Gist options
  • Save ndelangen/28d8f715897e626a25651848e695f1f2 to your computer and use it in GitHub Desktop.
Save ndelangen/28d8f715897e626a25651848e695f1f2 to your computer and use it in GitHub Desktop.
To communicate with the child process we need to enable.
const fork = require('child_process').fork;
const program = path.resolve('program.js');
const parameters = [];
const options = {
stdio: [ 'pipe', 'pipe', 'pipe', 'ipc' ]
};
const child = fork(program, parameters, options);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment