import {invariant} from "@onflow/util-invariant"
function add(a, b) {
invariant(typeof a === "number", "add(a, b) -- `a` needs to be a number", { a, b })
invariant(typeof b === "number", "add(a, b) -- `b` needs to be a number", { a, b })
return a + b
}
@onflow/util-invariant
1.2.2 • Public • PublishedReadme
Keywords
nonePackage Sidebar
Install
npm i @onflow/util-invariant
Repository
Homepage
Weekly Downloads
11,483
Version
1.2.2
License
Apache-2.0
Unpacked Size
15.8 kB
Total Files
14