ts-type-forge
    Preparing search index...

    Type Alias GetBrandValuePart<B>

    GetBrandValuePart: B extends Brand<
        infer T,
        UnwrapBrandTrueKeys<B> & string,
        UnwrapBrandFalseKeys<B> & string,
    >
        ? T
        : never

    Extracts the underlying value type from a branded type.

    Type Parameters

    The underlying value type T that was branded

    type UserId = Brand<string, 'UserId'>;
    type UserIdValue = GetBrandValuePart<UserId>; // string

    type Age = Brand<number, 'Age' | 'positive'>;
    type AgeValue = GetBrandValuePart<Age>; // number