Skip to main content
Console.time - Web documentation
method Console.time
Private
Console.time(label?: string): void

Starts a timer you can use to track how long an operation takes

Examples

Example 1

console.time('operation');
// ... some code
console.timeEnd('operation');

Parameters

optional
label: string

Timer label. Defaults to 'default'

Return Type

void
Back to top