Skip to content

Commit f2cb86f

Browse files
committedMar 21, 2019
Tweak the TS definition
1 parent 3db7d2c commit f2cb86f

File tree

1 file changed

+16
-18
lines changed

1 file changed

+16
-18
lines changed
 

‎index.d.ts

+16-18
Original file line numberDiff line numberDiff line change
@@ -234,30 +234,30 @@ export interface ExecaReturnBase<StdoutStderrType> {
234234
killed: boolean;
235235
}
236236

237-
export interface ExecaSyncReturnValue<StdOutErrType = string>
238-
extends ExecaReturnBase<StdOutErrType> {
237+
export interface ExecaSyncReturnValue<StdoutErrorType = string>
238+
extends ExecaReturnBase<StdoutErrorType> {
239239
/**
240240
The exit code of the process that was run.
241241
*/
242242
code: number;
243243
}
244244

245-
export interface ExecaReturnValue<StdOutErrType = string>
246-
extends ExecaSyncReturnValue<StdOutErrType> {
245+
export interface ExecaReturnValue<StdoutErrorType = string>
246+
extends ExecaSyncReturnValue<StdoutErrorType> {
247247
/**
248248
The output of the process with `stdout` and `stderr` interleaved.
249249
*/
250-
all: StdOutErrType;
250+
all: StdoutErrorType;
251251

252252
/**
253253
Whether the process was canceled.
254254
*/
255255
isCanceled: boolean;
256256
}
257257

258-
export interface ExecaSyncError<StdOutErrType = string>
258+
export interface ExecaSyncError<StdoutErrorType = string>
259259
extends Error,
260-
ExecaReturnBase<StdOutErrType> {
260+
ExecaReturnBase<StdoutErrorType> {
261261
/**
262262
The error message.
263263
*/
@@ -269,27 +269,25 @@ export interface ExecaSyncError<StdOutErrType = string>
269269
code: number | string;
270270
}
271271

272-
export interface ExecaError<StdOutErrType = string>
273-
extends ExecaSyncError<StdOutErrType> {
272+
export interface ExecaError<StdoutErrorType = string>
273+
extends ExecaSyncError<StdoutErrorType> {
274274
/**
275275
The output of the process with `stdout` and `stderr` interleaved.
276276
*/
277-
all: StdOutErrType;
277+
all: StdoutErrorType;
278278

279279
/**
280280
Whether the process was canceled.
281281
*/
282282
isCanceled: boolean;
283283
}
284284

285-
export interface ExecaChildPromise<StdOutErrType> {
285+
export interface ExecaChildPromise<StdoutErrorType> {
286286
catch<ResultType = never>(
287287
onRejected?:
288-
| ((
289-
reason: ExecaError<StdOutErrType>
290-
) => ResultType | PromiseLike<ResultType>)
288+
| ((reason: ExecaError<StdoutErrorType>) => ResultType | PromiseLike<ResultType>)
291289
| null
292-
): Promise<ExecaReturnValue<StdOutErrType> | ResultType>;
290+
): Promise<ExecaReturnValue<StdoutErrorType> | ResultType>;
293291

294292
/**
295293
Cancel the subprocess.
@@ -299,9 +297,9 @@ export interface ExecaChildPromise<StdOutErrType> {
299297
cancel(): void;
300298
}
301299

302-
export type ExecaChildProcess<StdOutErrType = string> = ChildProcess &
303-
ExecaChildPromise<StdOutErrType> &
304-
Promise<ExecaReturnValue<StdOutErrType>>;
300+
export type ExecaChildProcess<StdoutErrorType = string> = ChildProcess &
301+
ExecaChildPromise<StdoutErrorType> &
302+
Promise<ExecaReturnValue<StdoutErrorType>>;
305303

306304
declare const execa: {
307305
/**

0 commit comments

Comments
 (0)
Please sign in to comment.