Closed igrigorik closed 9 years ago
Using the entry settings object would be really weird. That's not what new Text
does, for sure. It can sometimes make sense for base URIs, less often for origins, never for anything else.
If you want to do what new Text
does, I suspect that's using the global of the Realm of the Text
function. At least in browsers. The spec for new Text
doesn't really define the behavior because it talks about "the global object", which is not a defined concept in general. /cc @annevk
I still think the implicit magic is bad, but could live with it as long as it's defined properly.
We really need better hooks from HTML and IDL. Including some guidelines. Or a pattern that people can copy.
Yes, we do.
@annevk @bzbarsky I'd appreciate any suggestions for how to spec this. Do we have any existing open issues to define such hooks?
I filed bugs against IDL and also HTML, but W3C Bugzilla is down at the moment.
Great, thanks! It'll be great to have URLs to those.
In the meantime, since folks are already implementing this interface, should we revert back to new PerformanceObserver
and add a note to clarify the spec language once above bugs are resolved?
Why are we doing this API when we'll get FetchObserver
?
Because Performance APIs are not restricted to fetch events - e.g. Frame Timing, Memory (assuming we take that on), and so on.
In the meantime, since folks are already implementing this interface, should we revert back to new PerformanceObserver and add a note to clarify the spec language once above bugs are resolved?
@mpb would you be up to create a pull to revert the constructor interface? I'm not hearing any loud objections.. think we should be ok to proceed :)
resolved via #43.
https://github.com/w3c/performance-timeline/pull/29 landed
window.performance.createPerformanceObserver
, but we have a few -1's on the new API:To lookup the performance object we can reference the "entry settings object" (EventSource example).
Any other implementation or other concerns with this API? Should we go back to
new PerformanceObserver
?/cc @bzbarsky @esprehn @domenic