vtils

Home > types > PickBy

PickBy type

Pick all properties of given type in object type

Signature:

export declare type PickBy<T, P> = Pick<
T,
    {
    [K in keyof T]: T[K] extends P ? K : never;
}[keyof T]
>;