interface Performance
Deno supports User Timing Level 3 which is not widely supported yet in other runtimes.
Check out the Performance API documentation on MDN for further information about how to use the API.
Methods #
#mark(markName: string,options?: PerformanceMarkOptions,): PerformanceMarkStores a timestamp with the associated name (a "mark").
#measure(measureName: string,options?: PerformanceMeasureOptions,): PerformanceMeasureStores the DOMHighResTimeStamp duration between two marks along with the
associated name (a "measure").
Properties #
#timeOrigin: numberReturns a timestamp representing the start of the performance measurement.
Methods #
#clearMarks(markName?: string): voidRemoves the stored timestamp with the associated name.
#clearMeasures(measureName?: string): voidRemoves stored timestamp with the associated name.
#getEntriesByName(name: string,type?: string,): PerformanceEntryList#getEntriesByType(type: string): PerformanceEntryList#mark(markName: string,options?: PerformanceMarkOptions,): PerformanceMarkStores a timestamp with the associated name (a "mark").
#measure(measureName: string,options?: PerformanceMeasureOptions,): PerformanceMeasureStores the DOMHighResTimeStamp duration between two marks along with the
associated name (a "measure").
#measure(measureName: string,startMark?: string,endMark?: string,): PerformanceMeasureStores the DOMHighResTimeStamp duration between two marks along with the
associated name (a "measure").
Returns a current time from Deno's start in fractional milliseconds.
const t = performance.now();
console.log(`${t} ms since start!`);
variable Performance
Properties #
#prototype: Performance