hd-utils
Version:
A handy utils for modern JS developers
10 lines (9 loc) • 413 B
JavaScript
import isEmpty from './isEmpty';
import isNullOrUndefined from './isNullOrUndefined';
import { isString } from './isString';
/**
* @description It returns true if the value is null, undefined, or an empty string
* @param {string | null} [value] - The value to check.
*/
const isNullOrEmptyString = (value) => isNullOrUndefined(value) || (isString(value) && isEmpty(value));
export default isNullOrEmptyString;