export const isClass = <T>(value: unknown): value is Constructor<T> => { return typeof value === "function" && typeof value.prototype === "object"; }; export type Constructor<T> = new (...args: unknown[]) => T;