@zingle/fail

0.0.1 • Public • Published

Use the fail function to print an error and exit.

Usage

const http = require("http");
const fail = require("@zingle/fail");

// exits with 100 exit status on timeout
http
    .request("http://www.example.com/foo")
    .on("timeout", () => fail(new Error("took too long"), 100));

Readme

Keywords

none

Package Sidebar

Install

npm i @zingle/fail

Weekly Downloads

2

Version

0.0.1

License

MIT

Unpacked Size

3.07 kB

Total Files

6

Last publish

Collaborators

  • njovin
  • oleksandr.vladymyrov
  • rremer
  • lmedrano
  • llongo-medallia