Nanoscale assertion module
var assert =
declaration is truthy otherwise throw
stack trace with this error.
If you want friendlier messages you can use template strings to show the
assertion made like in the example above.
I like to write public facing code very defensively, but have reservations about
the size incurred by the
assert module. I only use the top-level
Docs for the previous version, which is used by many modules on npm, can be found here
npm install nanoassert