@sharyn/util.exists
v1.0.1
Published
**`exists`** returns `true` if its argument is not `null` or `undefined`.
Downloads
8
Readme
🌹 exists
exists
returns true
if its argument is not null
or undefined
.
import exists from '@sharyn/util/exists'
// or import { exists } from '@sharyn/util'
exists('a') // true
exists('') // true
exists(0) // true
exists(NaN) // true
exists(null) // false
exists(undefined) // false
exists(void 0) // false
exists
is part of @sharyn/util