movie-web/src/utils/typeguard.ts
2023-07-23 16:30:22 +02:00

6 lines
119 B
TypeScript

export function isNotNull<T>(obj: T | null): obj is T {
return obj != null;
}
export type ValuesOf<T> = T[keyof T];