Skip to content

仓库 files navigation

📭Empty Checker

License Travis CI Coverage Status Commitizen

📭js-is-empty makes your empty checks for you. We have empty checks for

  • Array
  • Object
  • String

Installation

js-is-empty is available on npm/yarn:

$ npm install @codevor/js-is-empty --save
$ yarn add @codevor/js-is-empty

Usage

With ES6/import

import { isArrayEmpty, isObjectEmpty } from '@codevor/js-is-empty';

const myEmptyArray = [];
const person = { name: 'John Doe', age: 32 };

isArrayEmpty(myEmptyArray); // => true
isObjectEmpty(person); // => false

With require

const jsIsEmpty = require('@codevor/js-is-empty');

const isArrayEmpty = jsIsEmpty.isArrayEmpty;
const isObjectEmpty = jsIsEmpty.isObjectEmpty;

const myEmptyArray = [];
const person = { name: 'John Doe', age: 32 };

isArrayEmpty(myEmptyArray); // => true
isObjectEmpty(person); // => false

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Changelog

This project adheres to Semantic Versioning. Every release, along with the migration instructions, is documented on the Github 发布 page.

Bugs and Sugestions

Report bugs or do suggestions using the issues.

License

MIT License © Codevor

关于

📭 Basic Empty Checker Library

Topics

Resources

Contributing

Stars

1 star

关注者

1 watching

复刻s

发布

Used by

贡献者

Languages