Skip to content

Commit

Permalink
Merge pull request #3 from jayvdb/add-types
Browse files Browse the repository at this point in the history
Add TypeScript types definition
  • Loading branch information
vladikoff authored Dec 2, 2024
2 parents 0947a06 + f799468 commit a1cb5ce
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
8 changes: 8 additions & 0 deletions lib/exit.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/// <reference types="node" />

/**
* A replacement for process.exit that ensures stdio are fully drained before exiting.
*/
declare function exit(code: number, streams?: [NodeJS.WritableStream, NodeJS.WritableStream]): void;

export = exit;
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,18 @@
"name": "exit-x",
"description": "A replacement for process.exit that ensures stdio are fully drained before exiting.",
"version": "0.2.1",
"homepage": "https://github.com/cowboy/node-exit",
"homepage": "https://github.com/gruntjs/node-exit-x",
"author": "Grunt Development Team (https://gruntjs.com/development-team)",
"repository": {
"type": "git",
"url": "git://github.com/gruntjs/node-exit-x.git"
},
"bugs": {
"url": "https://github.com/gruntjs/node-exit/issues"
"url": "https://github.com/gruntjs/node-exit-x/issues"
},
"license": "MIT",
"main": "lib/exit",
"main": "lib/exit.js",
"types": "lib/exit.d.ts",
"engines": {
"node": ">= 0.8.0"
},
Expand Down

0 comments on commit a1cb5ce

Please sign in to comment.