Skip to main content

Module sleep_compat

Module sleep_compat 

Source
Expand description

Cross-platform async sleep for native and WASM targets Cross-platform async sleep for native and WASM targets

This module provides a unified sleep function that uses tokio::time::sleep on native targets and futures_timer::Delay on WASM targets.

Functionsยง

sleep
Asynchronously sleeps for the specified duration.