throw.flow

0.2.0 • Public • Published

throw.flow version Build Status styled with prettier

throw expression as a function

Import

import crash from "throw.flow"

API

throw

Just throws given error. Function is also generic and has a output type parameter so that it's return type can be treated as anything you want.

import crash from "throw.flow"
crash(new Error("Boom")) // => Error: Boom

Parameters

  • error reason

Returns output

Install

yarn add throw.flow --save

or with npm

npm install throw.flow --save

Dependencies (0)

    Dev Dependencies (10)

    Package Sidebar

    Install

    npm i throw.flow

    Weekly Downloads

    2

    Version

    0.2.0

    License

    MIT

    Last publish

    Collaborators

    • gozala