mirror of
https://github.com/outline/outline.git
synced 2026-01-06 11:09:55 -06:00
9 lines
268 B
TypeScript
9 lines
268 B
TypeScript
/**
|
|
* Returns a promise that resolves after a specified number of milliseconds.
|
|
*
|
|
* @param [delay=1] The number of milliseconds to wait before fulfilling the promise.
|
|
*/
|
|
export function sleep(ms = 1) {
|
|
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
}
|