util-nonempty
Version: 
Is the input (plain object, array, string or whatever) not empty?
11 lines (9 loc) • 450 B
JavaScript
/**
 * @name util-nonempty
 * @fileoverview Is the input (plain object, array, string or whatever) not empty?
 * @version 5.1.0
 * @author Roy Revelt
 * @license MIT
 * {@link https://codsen.com/os/util-nonempty/}
 */
import{isPlainObject as r}from"codsen-utils";var t="5.1.0";var p=t;function l(e){return e==null?!1:Array.isArray(e)||typeof e=="string"?!!e.length:r(e)?!!Object.keys(e).length:typeof e=="number"}export{l as nonEmpty,p as version};