Signed-off-by: Jérôme Benoit <jerome.benoit@piment-noir.org>
}
public static isIterable<T>(obj: T): boolean {
- if (obj) {
- return typeof obj[Symbol.iterator] === 'function';
- }
- return false;
+ return obj ? typeof obj[Symbol.iterator] === 'function' : false;
}
public static isString(value: unknown): boolean {
}
public static isNullOrUndefined(value: unknown): boolean {
- // eslint-disable-next-line no-eq-null, eqeqeq
- if (value == null) {
- return true;
- }
- return false;
+ // eslint-disable-next-line eqeqeq, no-eq-null
+ return value == null ? true : false;
}
public static isEmptyArray(object: unknown): boolean {