2023-08-25 01:26:47 +01:00
|
|
|
#import <PerformanceTimeline/PerformanceObserverEntryList.idl>
|
|
|
|
|
|
|
|
|
|
// https://w3c.github.io/performance-timeline/#dom-performanceobservercallbackoptions
|
|
|
|
|
dictionary PerformanceObserverCallbackOptions {
|
|
|
|
|
unsigned long long droppedEntriesCount;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
callback PerformanceObserverCallback = undefined (PerformanceObserverEntryList entries, PerformanceObserver observer, optional PerformanceObserverCallbackOptions options = {});
|
|
|
|
|
|
|
|
|
|
// https://w3c.github.io/performance-timeline/#dom-performanceobserverinit
|
|
|
|
|
dictionary PerformanceObserverInit {
|
|
|
|
|
sequence<DOMString> entryTypes;
|
|
|
|
|
DOMString type;
|
|
|
|
|
boolean buffered;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
// https://w3c.github.io/performance-timeline/#dom-performanceobserver
|
2023-09-03 02:00:01 +12:00
|
|
|
[Exposed=(Window,Worker)]
|
2023-08-25 01:26:47 +01:00
|
|
|
interface PerformanceObserver {
|
|
|
|
|
constructor(PerformanceObserverCallback callback);
|
|
|
|
|
undefined observe(optional PerformanceObserverInit options = {});
|
|
|
|
|
undefined disconnect();
|
|
|
|
|
PerformanceEntryList takeRecords();
|
2025-04-25 10:13:26 -04:00
|
|
|
// FIXME: This should be FrozenArray<DOMString>, but must also always return the same object.
|
2024-04-01 14:03:57 +01:00
|
|
|
[SameObject] static readonly attribute any supportedEntryTypes;
|
2023-08-25 01:26:47 +01:00
|
|
|
};
|