Arg Assert
Simple, tiny assertion library designed for making assertions about function
arguments.
NOTE: when I use the term "truthy" in these docs, I do not use it in the sense
usually understood in javascript. In these docs, "truthy" means not null,
undefined, or false.
Installation
npm install --save-dev arg-assert
API
assert
assertAll
Tip: This is especially nice when asserting a number of arguments are non-null,
and if you are using es6, you can use deconstruction to keep your code compact.
Example:
function(a, b, c) {
assertAll({a, b, c});
}