cosmic::iced_widget

Function component

source
pub fn component<'a, C, Message, Theme, Renderer>(
    component: C,
) -> Element<'a, Message, Theme, Renderer>
where C: Component<Message, Theme, Renderer> + 'a, <C as Component<Message, Theme, Renderer>>::State: 'static, Message: 'a, Theme: 'a, Renderer: Renderer + 'a,
👎Deprecated since 0.13.0: components introduce encapsulated state and hamper the use of a single source of truth. Instead, leverage the Elm Architecture directly, or implement a custom widget
Expand description

Turns an implementor of Component into an Element that can be embedded in any application.