pub struct Element { /* private fields */ }
Expand description
Why not react_sys::Element
react_sys::Element
, created from ReactJs,
can be cloned freely.
However, when it is created from frender component, it contains data from rust, which can’t be stored in react_sys::Element.
Due to the same reason, Element
implements From<react_sys::Element>
but not Into<react_sys::Element>
Implementations
sourceimpl Element
impl Element
pub fn from_js_element(el: Element) -> Self
pub fn bridge_use_render<E: IntoOptionalElement, F: 'static + Fn() -> E>(
use_render: F,
key: Option<Key>,
debug_component_name: Option<JsValue>,
debug_props: Option<JsValue>
) -> Self
pub fn bridge_use_render_element(el: UseRenderElement) -> Self
pub fn bridge_js(js: JsBridgeElement) -> Self
pub fn fragment(fe: FragmentElement) -> Self
Trait Implementations
sourceimpl IntoElement for Element
impl IntoElement for Element
fn into_element(self) -> Element
Auto Trait Implementations
impl !RefUnwindSafe for Element
impl !Send for Element
impl !Sync for Element
impl Unpin for Element
impl !UnwindSafe for Element
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more