@juspay/neurolink
Version:
Universal AI Development Platform with working MCP integration, multi-provider support, voice (TTS/STT/realtime), and professional CLI. 58+ external MCP servers discoverable, multimodal file processing, RAG pipelines. Build, test, and deploy AI applicatio
41 lines (40 loc) • 944 B
TypeScript
/**
* Delay Utilities
*
* Promise-based delay/sleep functions for async flow control.
*/
/**
* Delay execution for a specified number of milliseconds.
*
* This is the canonical implementation for promise-based delays.
*
* @param ms - Duration to wait in milliseconds
* @returns Promise that resolves after the specified delay
*
* @example
* ```typescript
* await delay(1000); // Wait 1 second
* ```
*
* @example
* ```typescript
* // Use in a loop for polling
* while (condition) {
* await checkStatus();
* await delay(500);
* }
* ```
*/
export declare function delay(ms: number): Promise<void>;
/**
* Alias for delay - provided for code clarity in sleep-like contexts.
*
* @param ms - Duration to sleep in milliseconds
* @returns Promise that resolves after the specified duration
*
* @example
* ```typescript
* await sleep(2000); // Sleep for 2 seconds
* ```
*/
export declare const sleep: typeof delay;