@aptos-labs/ts-sdk
Version:
Aptos TypeScript SDK
13 lines (11 loc) • 323 B
text/typescript
// Copyright © Aptos Foundation
// SPDX-License-Identifier: Apache-2.0
/**
* Sleep the current thread for the given amount of time
* @param timeMs time in milliseconds to sleep
*/
export async function sleep(timeMs: number): Promise<null> {
return new Promise((resolve) => {
setTimeout(resolve, timeMs);
});
}