waitUntilTimeout<T, E>(promise, timeoutMs, throwError?): Promise<Throws<T, E | IdleTimeoutError>>
Race a promise against an idle timeout. If the promise does not settle within
timeoutMs milliseconds, the returned promise rejects with IdleTimeoutError
(or the error returned by throwError when provided).
The timer is properly cleaned up on settlement to avoid leaking handles.
Race a promise against an idle timeout. If the promise does not settle within
timeoutMsmilliseconds, the returned promise rejects with IdleTimeoutError (or the error returned bythrowErrorwhen provided). The timer is properly cleaned up on settlement to avoid leaking handles.