pub trait ElementExt: AsRef<Element> + Clone {
// Provided methods
fn class(&self, c: impl AsRef<str>) -> Self { ... }
fn bclass(&self, c: impl AsRef<str>, value: bool) -> Self { ... }
fn attr(&self, name: impl AsRef<str>, value: impl AsRef<str>) -> Self { ... }
fn iattr(&self, name: impl AsRef<str>, value: impl Into<i32>) -> Self { ... }
fn battr(&self, name: impl AsRef<str>, value: bool) -> Self { ... }
}Provided Methods§
Sourcefn attr(&self, name: impl AsRef<str>, value: impl AsRef<str>) -> Self
fn attr(&self, name: impl AsRef<str>, value: impl AsRef<str>) -> Self
Set the attribute name to the specified value
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".