@amxdev/is-empty
v1.0.0
Published
Utility to check if a value is empty (null, undefined, string, array, or object)
Maintainers
Readme
@amxdev/is-empty
A lightweight utility to check if a value is empty.
Install
npm install @amxdev/is-empty
import { isEmpty } from "@amxdev/is-empty";
isEmpty(null); // true
isEmpty(""); // true
isEmpty([]); // true
isEmpty({}); // true
isEmpty("hello"); // false
isEmpty([1, 2]); // false