Closed kenchris closed 6 months ago
LGTM, Would be good to have another reviewer on that one as well.
@tomayac Arnaud has another PR up for changing the explainer etc.
If it is 0, it will get as fast as the system can handle:
If timeDeltaMilliseconds ≥ sampleInterval, return true, otherwise return false.
We could consider using something else, mind filing an issue?
LGTM.
https://wicg.github.io/periodic-background-sync/#periodic-sync-registration-minimum-interval <- also uses minInterval of 0 (as fast as system allows)
https://wicg.github.io/js-self-profiling/#the-profilersample-dictionary says it must be 0 or bigger, but doesn't even check whether it is not undefined
Yes, for the same source type that makes sense, but we need to spec things differently when we support multiple sources. We do support two sources now in the spec, but makes sense to postpone this change till after shipping, to not give @arskama unneeded work as this is purely a spec change for now.
PerformanceObserver works the same way. A consecutive call to observe is seen as an update, and in the case some update is incompatible (like moving from one type to multiple) which is not a problem for us, then they throw "InvalidModificationError".
Anyway, here is a PR we can merge when we decide to https://github.com/w3c/compute-pressure/pull/263
Fixes #259
Preview | Diff