# spawnd

> Spawn a dependent child process.

Latest version **11.0.0** (published 2024-12-21) · MIT license · 0 weekly downloads

## Install

```sh
npm install spawnd
pnpm add spawnd
yarn add spawnd
bun add spawnd
```

## Health

**Score 45/100 (D)** — status: stable.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: stale.

## Facts

| | |
|---|---|
| Version | 11.0.0 |
| Published | 2024-12-21 |
| First published | 2018-03-04 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=18 |
| Dependencies | 2 |
| Unpacked size | 4.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3544 |
| Maintainers | neoziro, tonybrix |
| Keywords | spawn, exec, process, child_process, dependent, exit, child |

## Links

- npm: https://www.npmjs.com/package/spawnd
- Repository: https://github.com/argos-ci/jest-puppeteer
- Homepage: https://github.com/argos-ci/jest-puppeteer/tree/main/packages/spawnd#readme
- Issues: https://github.com/argos-ci/jest-puppeteer/issues
- npm.io page: https://npm.io/package/spawnd

## Dependencies (2)

- [tree-kill](https://npm.io/package/tree-kill.md) ^1.2.2
- [signal-exit](https://npm.io/package/signal-exit.md) ^4.1.0

## Recent versions

- 11.0.0 (latest) — 2024-12-21
- 10.1.4 — 2024-10-26
- 10.1.1 — 2024-09-06
- 10.1.0 — 2024-08-17
- 10.0.0 — 2024-02-10
- 9.0.2 — 2023-12-06
- 9.0.1 — 2023-10-01
- 9.0.0 — 2023-05-24
- 8.0.5 — 2023-03-09
- 8.0.0 — 2023-03-06
- 7.0.0 — 2023-02-03
- 6.2.0 — 2022-12-11
- 6.0.2 — 2021-11-25
- 6.0.0 — 2021-09-23
- 5.0.0 — 2021-04-16
- … 8 more at https://npm.io/package/spawnd/versions

## README

# spawnd

[![npm version](https://img.shields.io/npm/v/spawnd.svg)](https://www.npmjs.com/package/spawnd)
[![npm dm](https://img.shields.io/npm/dm/spawnd.svg)](https://www.npmjs.com/package/spawnd)
[![npm dt](https://img.shields.io/npm/dt/spawnd.svg)](https://www.npmjs.com/package/spawnd)

Spawn a process inter-dependent with parent process.

```
npm install spawnd
```

## Usage

```js
import { spawnd } from "spawnd";

const proc = spawnd("node server.js", { shell: true });

proc.destroy().then(() => {
  console.log("Destroyed!");
});
```

## API

### spawnd(command[, args[, options]])

Exactly the same API as [Node.js spawn](https://nodejs.org/api/child_process.html#child_process_child_process_spawn_command_args_options).

It returns a [Child Process](https://nodejs.org/api/child_process.html#child_process_class_childprocess) that exposes a destroy method that will kill the process.

---
_Source: https://npm.io/package/spawnd · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
