- From: vmpstr <notifications@github.com>
- Date: Tue, 21 Jun 2022 08:21:14 -0700
- To: w3ctag/design-reviews <design-reviews@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Tuesday, 21 June 2022 15:21:26 UTC
> Has there been any discussion of making this async? In general we'd prefer not to add more functionality that synchronously blocks for style computation (or layout). We haven't considered making this asynchronous. IMHO it would complicate the API and code using it, to avoid a potential style (+ possibly layout) update. If my reading of https://www.w3.org/TR/design-principles/#synchronous is correct, the general preference is for synchronous APIs unless there is substantial I/O or heavy work. Again IMHO, I don't think style and layout qualify here. There is already a number of APIs like getBoundingClientRect that have to process style + layout. In other words, a number of existing APIs already work as if style and layout is always up-to-date from script perspective. I can't see a justification why this API should be different. -- Reply to this email directly or view it on GitHub: https://github.com/w3ctag/design-reviews/issues/734#issuecomment-1161907783 You are receiving this because you are subscribed to this thread. Message ID: <w3ctag/design-reviews/issues/734/1161907783@github.com>
Received on Tuesday, 21 June 2022 15:21:26 UTC