UNPKG

ramda-extension

Version:

Helpful functions built on top of the mighty Ramda

20 lines (19 loc) 557 B
import { gte } from 'ramda'; import { compareLength } from './internal/lengthUtils'; /** * Returns true if length of array is smaller or equals than first argument * * @func * @category List * * @example * * const lengthSmallerThanEqualsOne = R_.gteThanLength(1) * lengthSmallerThanEqualsTwo([{},{}]) // false * lengthSmallerThanEqualsTwo([{}]) // true * lengthSmallerThanEqualsTwo([]) // true * * @sig Number -> [a] -> Boolean */ var gteThanLength = /*#__PURE__*/compareLength(gte); export default gteThanLength;