/** For narrowing instance types with array.filter */ export const isInstanceOf = ( constructor: new (...args: Args) => Instance, ) => (value: unknown): value is Instance => value instanceof constructor