Our codebase contains a simpler version of this trait which we use to write helper functions which can be applied both at the top level to Html but also if selection is a multi-step process, i.e. to ElementRef itself, as the scope to which a CSS selector is applied.
Our codebase contains a simpler version of this trait which we use to write helper functions which can be applied both at the top level to
Html
but also if selection is a multi-step process, i.e. toElementRef
itself, as the scope to which a CSS selector is applied.Note that this uses generic associated type and hence requires Rust 1.65, c.f. https://blog.rust-lang.org/2022/10/28/gats-stabilization.html.