// usages
chance.falsy()
chance.falsy({ pool: [ NaN, undefined ] })
Return a random falsy value (false
, null
, undefined
, 0
, NaN
, ''
).
chance.falsy();
=> false
The default pool can be change to better meet the needs:
chance.falsy({ pool: [ NaN, undefined ] });
=> NaN