@adguard/agtree
Version:
Tool set for working with adblock filter lists
39 lines (37 loc) • 935 B
JavaScript
/*
* AGTree v4.1.1 (build date: Thu, 23 Apr 2026 09:15:37 GMT)
* (c) 2026 Adguard Software Ltd.
* Released under the MIT license
* https://github.com/AdguardTeam/tsurlfilter/tree/master/packages/agtree#readme
*/
/**
* Checks whether the given value is undefined.
*
* @param value Value to check.
*
* @returns `true` if the value is 'undefined', `false` otherwise.
*/
const isUndefined = (value) => {
return typeof value === 'undefined';
};
/**
* Checks whether the given value is null.
*
* @param value Value to check.
*
* @returns `true` if the value is 'null', `false` otherwise.
*/
const isNull = (value) => {
return value === null;
};
/**
* Checks whether the given value is a string.
*
* @param value Value to check.
*
* @returns `true` if the value is a string, `false` otherwise.
*/
const isString = (value) => {
return typeof value === 'string';
};
export { isNull, isString, isUndefined };