Rocky_Mountain_Vending/.pnpm-store/v10/files/8e/04cba352a707abc881f1e25f1d5385a2dabf10b005f33b54ec6744f63876b50757eeba9798d7a595f3f1abcc37371b4b893ed7117ec9fa00ff106bce8bd0fd
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

36 lines
1.8 KiB
Text

/**
* Converts a duration in seconds to a human-readable string format.
* Formats duration based on magnitude for optimal readability:
* - >= 2 minutes: show in minutes with 1 decimal place (e.g., "2.5min")
* - >= 40 seconds: show in whole seconds (e.g., "45s")
* - >= 2 seconds: show in seconds with 1 decimal place (e.g., "3.2s")
* - < 2 seconds: show in milliseconds with 1 decimal place (e.g., "1500.0ms")
*
* @deprecated Use durationToStringWithNanoseconds instead, collect time in nanoseconds using process.hrtime.bigint().
* @param compilerDuration - Duration in seconds as a number
* @returns Formatted duration string with appropriate unit and precision
*/
export declare function durationToString(compilerDuration: number): string;
/**
* Converts a high-resolution time tuple to seconds.
*
* @param hrtime - High-resolution time tuple of [seconds, nanoseconds]
* @returns Duration in seconds as a floating-point number
*/
export declare function hrtimeToSeconds(hrtime: [number, number]): number;
/**
* Converts a BigInt nanosecond duration to a human-readable string format.
* This is the preferred method for formatting high-precision durations.
*
* @param hrtime - Duration in nanoseconds as a BigInt (typically from process.hrtime.bigint())
* @returns Formatted duration string with appropriate unit and precision
*/
export declare function hrtimeBigIntDurationToString(hrtime: bigint): string;
/**
* Converts a high-resolution time tuple to a human-readable string format.
*
* @deprecated Use hrtimeBigIntDurationToString with process.hrtime.bigint() for better precision.
* @param hrtime - High-resolution time tuple of [seconds, nanoseconds]
* @returns Formatted duration string with appropriate unit and precision
*/
export declare function hrtimeDurationToString(hrtime: [number, number]): string;