@bodil/opt
    Preparing search index...

    Type Alias OkType<T>

    OkType: T extends Result<infer A, any> ? A : never

    Extract the type of the success value from a Result type.

    Type Parameters

    • T
    type VoteResult = Result<"yes" | "no", Error>;
    type VoteOk = OkType<VoteResult>; // "yes" | "no"