mirror of
https://gitee.com/bimuziyan/ccc-obfuscated-code.git
synced 2026-07-01 16:05:48 +08:00
336 B
336 B
bool
// 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