Returns true if value is null or undefined.
true
value
null
undefined
The value to check.
isNullish(null) // => trueisNullish(undefined) // => trueisNullish(0) // => false Copy
isNullish(null) // => trueisNullish(undefined) // => trueisNullish(0) // => false
Returns
trueifvalueisnullorundefined.