W3cubDocs

/DOM

PerformanceObserverEntryList

The PerformanceObserverEntryList interface is a list of peformance events that were explicitly observed via the observe() method.

Note: this interface is exposed to Window and Worker.

Methods

PerformanceObserverEntryList.getEntries()
Returns a list of explicitly observed PerformanceEntry objects based on the given filter.
PerformanceObserverEntryList.getEntriesByType()
Returns a list of explicitly observed PerformanceEntry objects of the given entry type.
PerformanceObserverEntryList.getEntriesByName()
Returns a list of explicitly observed PerformanceEntry objects based on the given name and entry type.

Example

// Create observer for all performance event types 
// list is of type PerformanceObserveEntryList
var observe_all = new PerformanceObserver(function(list, obs) {  
   var perfEntries; 
   // Print all entries perfEntries = list.getEntries(); 
   for (var i=0; i < perfEntries.length; i++) { 
      print_perf_entry(perfEntries[i]); 
      // do something with it 
   }
}

Specifications

Specification Status Comment
Performance Timeline Level 2
The definition of 'PerformanceObserverEntryList' in that specification.
Candidate Recommendation Initial definition.

Browser compatibilityUpdate compatibility data on GitHub

Desktop
Chrome Edge Firefox Internet Explorer Opera Safari
Basic support 52 ? 57 No 39 11
getEntries 52 ? 57 No 39 No
getEntriesByType 52 ? 57 No 39 No
getEntriesByName 52 ? 57 No 39 No
Mobile
Android webview Chrome for Android Edge Mobile Firefox for Android Opera for Android iOS Safari Samsung Internet
Basic support No 52 ? 57 39 11 ?
getEntries No 52 ? 57 39 No ?
getEntriesByType No 52 ? 57 39 No ?
getEntriesByName No 52 ? 57 39 No ?

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/PerformanceObserverEntryList