Skip to main content
Module

x/scaffold/src/deps/comlink.ts>Remote

scaffold your next project with style and 💗
Latest
type alias Remote
import { type Remote } from "https://deno.land/x/scaffold@0.3.0/src/deps/comlink.ts";

Takes the raw type of a remote object, function or class in the other thread and returns the type as it is visible to the local thread from the proxy return value of Comlink.wrap() or Comlink.proxy().

definition:
& (T extends (...args: infer TArguments) => infer TReturn ? (...args: [I in keyof TArguments]: UnproxyOrClone<TArguments[I]>) => Promisify<ProxyOrClone<Unpromisify<TReturn>>> : unknown)
& (T extends { new (...args: infer TArguments): infer TInstance; } ? { new (...args: [I in keyof TArguments]: UnproxyOrClone<TArguments[I]>): Promisify<Remote<TInstance>>; } : unknown)