1 | # Installation
|
2 | > `npm install --save @types/cross-spawn`
|
3 |
|
4 | # Summary
|
5 | This package contains type definitions for cross-spawn (https://github.com/moxystudio/node-cross-spawn).
|
6 |
|
7 | # Details
|
8 | Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/cross-spawn.
|
9 | ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/cross-spawn/index.d.ts)
|
10 | ````ts
|
11 | /// <reference types="node" />
|
12 |
|
13 | import * as child_process from "child_process";
|
14 |
|
15 | declare namespace spawn {
|
16 | /**
|
17 | * The `spawn()` method spawns a new process using the given `command`, with
|
18 | * command line arguments in `args`. If omitted, `args` defaults to an empty array.
|
19 | */
|
20 | const spawn: typeof child_process.spawn;
|
21 |
|
22 | /**
|
23 | * The `spawn.sync()` method spawns a new process using the given `command`, with
|
24 | * command line arguments in `args`. If omitted, `args` defaults to an empty array.
|
25 | */
|
26 | const sync: typeof child_process.spawnSync;
|
27 | }
|
28 |
|
29 | /**
|
30 | * The `spawn()` method spawns a new process using the given `command`, with
|
31 | * command line arguments in `args`. If omitted, `args` defaults to an empty array.
|
32 | */
|
33 | declare function spawn(command: string, options: child_process.SpawnOptions): child_process.ChildProcess;
|
34 | declare function spawn(
|
35 | command: string,
|
36 | args?: readonly string[],
|
37 | options?: child_process.SpawnOptions,
|
38 | ): child_process.ChildProcess;
|
39 |
|
40 | export = spawn;
|
41 |
|
42 | ````
|
43 |
|
44 | ### Additional Details
|
45 | * Last updated: Mon, 20 Nov 2023 23:36:24 GMT
|
46 | * Dependencies: [@types/node](https://npmjs.com/package/@types/node)
|
47 |
|
48 | # Credits
|
49 | These definitions were written by [Alorel](https://github.com/Alorel), and [ExE Boss](https://github.com/ExE-Boss).
|
50 |
|
\ | No newline at end of file |