is-obj-empty

    1.0.0 • Public • Published

    is-obj-empty

    npm typescript GitHub stars Twitter Follow

    Check if an object is empty.

    Installation

    yarn add is-obj-empty
    npm install is-obj-empty

    API

    Usage

    import isEmpty from "is-obj-empty";
     
    isEmpty({}); // true
    isEmpty({ a: undefined }); // false
    isEmpty({ a: true }); // false
     
    isEmpty([]); // true
    isEmpty([undefined]); // false
    isEmpty([true]); // false

    Types

    import isEmpty, { AnyObject } from "is-obj-empty";
     
    function isEmpty(object: AnyObject): boolean;
     
    type AnyObject = {
      [index in string | number]: any;
    }

    Dev DependenciesDavid

    License license

    MIT

    Install

    npm i is-obj-empty

    DownloadsWeekly Downloads

    1

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    2.89 kB

    Total Files

    6

    Last publish

    Collaborators

    • bconnorwhite