Module async_utils

Source
Expand description

Async utils

Re-exports§

pub use futures;

Macros§

join
Polls multiple futures simultaneously, returning a tuple of all results once complete.
select
Polls multiple futures and streams simultaneously, executing the branch for the future that finishes first. If multiple futures are ready, one will be pseudo-randomly selected at runtime. Futures directly passed to select! must be Unpin and implement FusedFuture.
try_join
Polls multiple futures simultaneously, resolving to a Result containing either a tuple of the successful outputs or an error.

Functions§

sleep
Sleeps for the given duration using js setTimeout.