@arpinum/defender1.0.1 • Public • Published
Every absurdity has a champion to defend it.
@arpinum/defender is a collection of assertions to do some runtime type checking.
npm install @arpinum/defender --save
Assertion throwing exception when not satisfied:
const assert = ;; // throws: value must be a number
Simple validation returning a boolean:
const is = ;; // false
More examples in examples.