Implement ResizeObserver #31006
Labels
A-content/css
Interacting with CSS from web content (parsing, serializing, introspection)
A-content/dom
Interacting with the DOM from web content
A-content/script
Related to the script thread
B-interesting-project
Represents work that is expected to be interesting in some fashion
E-candidate-for-mentoring
E-very-complex
Very difficult. Do not attempt without significant relevant experience and motivation.
Needed for #30822
Spec: https://drafts.csswg.org/resize-observer/#resize-observer-interface
One would have to add a new WebIDL(see
components/script/dom/webidl
), and expose the interface onWindow
.And then implement it in a new
components/script/dom/resizeobserver.rs
file. The WebIDL interface methods will be generated automatically and can be imported asuse crate::dom::bindings::codegen::Bindings::<interface name>
For the callback part,
components/script/dom/eventtarget.rs
is probably a good place to look for inspiration.The text was updated successfully, but these errors were encountered: