On Wed, Jan 31, 2024 at 8:54 PM Mason Freed <mas...@chromium.org> wrote:
> Contact emailsmas...@chromium.org > > ExplainerNone > > Specificationhttps://w3c.github.io/uievents/#legacy-event-types > > Summary > > Mutation Events, including `DOMSubtreeModified`, `DOMNodeInserted`, > `DOMNodeRemoved`, `DOMNodeRemovedFromDocument`, > `DOMNodeInsertedIntoDocument`, and `DOMCharacterDataModified`, are quite > bad for page performance, and also significantly increase the complexity of > adding new features to the Web. These APIs were deprecated from the spec ( > https://w3c.github.io/uievents/#legacy-event-types) in 2011, and were > replaced (in 2012) by the much better-behaved Mutation Observer API. Usage > of the obsolete Mutation Events must be migrated to Mutation Observer. > Mutation events are deprecated starting in Chrome 115, and support will be > disabled by default starting in Chrome 127, around July 30, 2024. A > Deprecation Trial will be available starting in Chrome 124, and extending > through Chrome 134, which can be used to extend the time a site has to > migrate by ~9 months, until March 25, 2025. > > > Blink componentBlink>DOM > <https://bugs.chromium.org/p/chromium/issues/list?q=component:Blink%3EDOM> > > Search tagsMutationEvent > <https://chromestatus.com/features#tags:MutationEvent>, DOMSubtreeModified > <https://chromestatus.com/features#tags:DOMSubtreeModified>, > DOMNodeInserted <https://chromestatus.com/features#tags:DOMNodeInserted>, > DOMNodeRemoved <https://chromestatus.com/features#tags:DOMNodeRemoved>, > DOMNodeRemovedFromDocument > <https://chromestatus.com/features#tags:DOMNodeRemovedFromDocument>, > DOMNodeInsertedIntoDocument > <https://chromestatus.com/features#tags:DOMNodeInsertedIntoDocument>, > DOMCharacterDataModified > <https://chromestatus.com/features#tags:DOMCharacterDataModified> > > TAG reviewNone > > TAG review statusNot applicable > > Chromium Trial NameMutationEvents > > Origin Trial documentation link > https://developer.chrome.com/blog/mutation-events-deprecation > > WebFeature UseCounter namekDOMNodeRemovedEvent > > Risks > > > Interoperability and Compatibility > > There are technically 9 Mutation Events, but Chromium only implements 6 of > them. Their use counters vary significantly: - DOMNodeInsertedIntoDocument: > 0.006% - DOMNodeRemovedFromDocument: 0.012% - DOMCharacterDataModified: > 0.016% - DOMNodeRemoved: 0.77% - DOMSubtreeModified: 0.81% - > DOMNodeInserted: 1.58% The DOMNodeInsertedIntoDocument and > DOMNodeRemovedFromDocument events are not fired by Gecko. That, plus the > low use counters for those two plus DOMCharacterDataModified, mean that > these three could likely be fairly easily removed after some time. The last > three have quite significant usage, and more study and outreach will be > required to bring this usage down below safe removal limits, which will > take significant time. Tentatively, we're aiming for M126 as the last > version of Chrome that supports the events above, ending July 30, 2024. > This npm package attempts to polyfill Mutation Events using Mutation > Observer: https://www.npmjs.com/package/mutation-events. > This is very exciting! Thank you for working on this. Do you know whether the existing usage is feature checked? 1.58% seems very high, but if it's feature checked and fallback is something like mutation observer, then it would be a lot more safe imho. Also, do you have a sense of where the usage is coming from (a few large frameworks vs a ton of smaller sites)? The npm package you listed, for example, would use the actual events if available, so sites using that polyfill would also count towards the event usage if the browser supports those even though that's "safe", right? > > *Gecko*: Positive ( > https://github.com/mozilla/standards-positions/issues/807) "very strong > positive position" > > *WebKit*: No signal ( > https://github.com/WebKit/standards-positions/issues/192) > > *Web developers*: No signals > > *Other signals*: > > WebView application risks > > Does this intent deprecate or change behavior of existing APIs, such that > it has potentially high risk for Android WebView-based applications? > > None > > > Goals for experimentation > > > > Ongoing technical constraints > > > > Debuggability > > > > Will this feature be supported on all six Blink platforms (Windows, Mac, > Linux, ChromeOS, Android, and Android WebView)?Yes > > Is this feature fully tested by web-platform-tests > <https://chromium.googlesource.com/chromium/src/+/main/docs/testing/web_platform_tests.md> > ?No > > Flag name on chrome://flags > > Finch feature nameNone > > Non-finch justificationNone > > Requires code in //chrome?False > > Tracking bughttps://crbug.com/1446498 > > Estimated milestones > Shipping on desktop 115 > OriginTrial desktop last 134 > OriginTrial desktop first 124 > Shipping on Android 115 > OriginTrial Android last 134 > OriginTrial Android first 124 > Shipping on WebView 115 > OriginTrial webView last 134 > OriginTrial webView first 124 > > Link to entry on the Chrome Platform Status > https://chromestatus.com/feature/5083947249172480 > > Links to previous Intent discussionsIntent to Experiment: > https://groups.google.com/a/chromium.org/g/blink-dev/c/qDsKRU-cQ_4/m/isA1mZ_aAAAJ > > > This intent message was generated by Chrome Platform Status > <https://chromestatus.com/>. > > -- > You received this message because you are subscribed to the Google Groups > "blink-dev" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to blink-dev+unsubscr...@chromium.org. > To view this discussion on the web visit > https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAM%3DNeDjevtANjMn1NUK83UGyJyv4HrLCFkjs9fhL6UVov_uAkA%40mail.gmail.com > <https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAM%3DNeDjevtANjMn1NUK83UGyJyv4HrLCFkjs9fhL6UVov_uAkA%40mail.gmail.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "blink-dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscr...@chromium.org. To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CADsXd2PEoqTd1FPqvD5zrJ%3D-_8ctvE8217L6XdU-nMXnH4P2yw%40mail.gmail.com.