-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide sync measurement methods within a special requestMeasurementFrame callback #838
Comments
Yes. Though I think we were considering removal/redesign of async measurement? |
Removed the owner. |
I don't know if we have this tracked in another bug or not, but having a nice "microtask" API to queue something that will happen before paint would be really useful as a general feature. |
This comment was originally written by [email protected] I am definitely interested in a "sync" version. I have implemented some code that is definitely overly-complex due to how the async version makes my application-execution-path utterly nonsensical without an equally strange workaround that requires me to put a callback into the future-based-async routine (current version) that, only on the first completion, actually launches my application through my desired-execution-path via what is essentially a new "main()" entry point provided in the callback. ughhh. |
For a microtask API- you should be able to use window.requestLayoutFrame for this purpose. I do find it a bit odd though that layout effectively runs at a higher priority than animation though, so we may want to consider some name changes here. |
The synchronous measurement APIs have been unhidden, no need to use requestMeasurementFrame. Added Fixed label. |
Revisions updated by `dart tools/rev_sdk_deps.dart`. protobuf (https://github.com/dart-lang/protobuf/compare/da6953c..edf8e92): edf8e92 2023-06-09 Ömer Sinan Ağacan Fix parsing negative JSON values for uint32 fields (#839) 2931b2e 2023-06-09 Ömer Sinan Ağacan Add PR links to recent CHANGELOG entries (#838) test (https://github.com/dart-lang/test/compare/7a6c98d..e7ae613): e7ae6139 2023-06-08 Nate Bosch Remove redundant type checks (#2031) webdev (https://github.com/dart-lang/webdev/compare/3d7f546..a6d761d): a6d761d8 2023-06-08 Elliott Brooks Remove tabs permission (#2136) b02b344e 2023-06-08 Elliott Brooks Catch `WipError` on calls to resume and map to appropriate RPC error code (#2134) Change-Id: I58b111a433cef76a501c959f33db4e5463a34c60 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/308380 Auto-Submit: Devon Carew <[email protected]> Reviewed-by: Konstantin Shcheglov <[email protected]> Commit-Queue: Konstantin Shcheglov <[email protected]>
Within this callback, any calls mutating the DOM should trigger an assert in dev mode.
The text was updated successfully, but these errors were encountered: