UNPKG

ramda-extension

Version:

Helpful functions built on top of the mighty Ramda

22 lines (21 loc) 464 B
import { anyPass, isEmpty, isNil } from 'ramda'; /** * Returns true if input is empty or nil. * * @func * @category Logic * * @param {any} input * @return {Boolean} * * @example * * R_.isNilOrEmpty(null) // true * R_.isNilOrEmpty({}) // true * R_.isNilOrEmpty(false) // false * R_.isNilOrEmpty(0) // false * * @sig a -> Boolean */ var isNilOrEmpty = /*#__PURE__*/anyPass([isNil, isEmpty]); export default isNilOrEmpty;