@klevu/core
Version:
Typescript SDK that simplifies development on Klevu backend. Klevu provides advanced AI-powered search and discovery solutions for online retailers.
16 lines (15 loc) • 354 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.notEmpty = void 0;
/**
* Type safe version to remove nulls and undefineds from array
*
* usage: `myArray.filter(notEmpty)`
*
* @param value
* @returns
*/
function notEmpty(value) {
return value !== null && value !== undefined;
}
exports.notEmpty = notEmpty;