rittenhop-dev/versions/5.94.2/node_modules/bail
2024-09-23 19:40:12 -04:00
..
index.js first commit 2024-09-23 19:40:12 -04:00
license first commit 2024-09-23 19:40:12 -04:00
package.json first commit 2024-09-23 19:40:12 -04:00
readme.md first commit 2024-09-23 19:40:12 -04:00

bail

Build Coverage Downloads Size

⚠️ Throw a given error.

Install

npm:

npm install bail

Use

var bail = require('bail')

bail()

bail(new Error('failure'))
// Error: failure
//     at repl:1:6
//     at REPLServer.defaultEval (repl.js:154:27)
//     …

API

bail([err])

Throw a given error.

Parameters
  • err (Error?) — Optional error.
Throws
  • Error — Given error, if any.

License

MIT © Titus Wormer