wintercg / proposal-common-minimum-api

https://common-min-api.proposal.wintercg.org/
Other
227 stars 13 forks source link

Web Perf #15

Closed legendecas closed 2 years ago

legendecas commented 2 years ago

Currently, the implementation status of the WebPerf spec is as following table:

Spec API Node.js Deno Cloudflare Worker
User Timing Performance.mark
User Timing Performance.measure
User Timing Performance.clearMarks
User Timing Performance.clearMeasures
Performance Timeline Performance.getEntries
Performance Timeline Performance.getEntriesByType
Performance Timeline Performance.getEntriesByName
Performance Timeline PerformanceObserver
High Resolution Time Performance.now
High Resolution Time Performance.timeOrigin ✅ Pending
Resource Timing PerformanceResourceTiming Pending

I believe APIs that are included in User Timing, Performance Timeline, and HR Time are met the bar of at least two runtimes implemented and can be added to the list of the common minimum api.

jasnell commented 2 years ago

@lucacasonato ... does Deno have plans to implement PerformanceObserver?

I can say definitively that Workers will not be providing an impl of this API for general users due to a number of spectre-related security concerns but it definitely does meet the basic At-Least-Two criteria.

lucacasonato commented 2 years ago

Yes, we want to implement that API in the limit.

@legendecas Deno is shipping timeOrigin in 1.22 (tomorrow) by the way

jasnell commented 2 years ago

We spoke briefly about this on the last wintercg call. Where we landed was that this likely falls under the "normative optional" category. That is, it doesn't likely belong in the minimum common api document but, if it is going to be implemented it should be done in a consistent way. A separate note documenting the minimum expectations should be written up.

legendecas commented 2 years ago

Created https://github.com/wintercg/performance/issues/2 to continue the efforts.