HostInterface<T>: {
    [K in keyof T]: T[K] extends CallableFunction
        ? HostOf<T[K]>
        : T[K] extends Record<string, any>
            ? Simplify<HostInterface<T[K]>>
            : T[K]
}

Convert an entire Guest interface into what the host will implement.

Type Parameters

  • T