Check if something exists (e.g. not null
|| undefined
)
A modularized version of the existy
function found in Functional Javascript by Michael Fogus.
$ npm i existy --save
var existy = require('existy')
existy(null) // false
existy(undefined) // false
existy(0) // true
existy(false) // true
Contributions welcome! Please read the contributing guidelines first.
- Functional Javascript by Michael Fogus
- "this is my best module" - substack