UNPKG

@bitty/falsy

Version:

Falsy helper functions and types for TypeScript.

1 lines 714 B
{"version":3,"file":"main.mjs","sources":["../src/main.js"],"sourcesContent":["/**\n * Union of values that is considered false when converted to `Boolean`.\n * @see {@link https://developer.mozilla.org/en-US/docs/Glossary/Falsy}.\n * @typedef {false | void | '' | 0 | 0n | null | undefined} Falsy\n */\n/**\n * Check if value is falsy (`\"\"`, `null`, `false`, `0`, `NaN` or `undefined`).\n * @param {*} value - The value that will be checked.\n * @returns {Boolean}\n */\nexport default function isFalsy(value) {\n return !value;\n}\n//# sourceMappingURL=main.js.map"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACe,SAAS,OAAO,CAAC,KAAK,EAAE;AACvC,IAAI,OAAO,CAAC,KAAK;AACjB;;;;"}