Unstubify<T>: T extends StubBase<infer V>
    ? V
    : T extends Map<infer K, infer V>
        ? Map<Unstubify<K>, Unstubify<V>>
        : T extends Set<infer V>
            ? Set<Unstubify<V>>
            : T extends (infer V)[]
                ? Unstubify<V>[]
                : T extends ReadonlyArray<infer V>
                    ? ReadonlyArray<Unstubify<V>>
                    : T extends {
                            [key: string | number]: unknown;
                        }
                        ? {
                            [K in keyof T]: Unstubify<T[K]>
                        }
                        : T

Type Parameters

  • T