my-swiss-knife: - v1.9.9
    Preparing search index...

    Type Alias ExtractPropertyType<T, K>

    ExtractPropertyType: T[K]

    Extracts the type of a specific property from a given object type.

    For example: type User = { id: number; name: string }; ExtractPropertyType<User, 'id'> -> number

    Type Parameters

    • T

      The object type

    • K extends keyof T

      The key of the property to extract

    The type of the specified property

    export type ExtractPropertyType<T, K extends keyof T> = T[K]