ori::prelude

Function opaque

Source
pub fn opaque<V>(content: V) -> Opaque<V>
where V: View,
Expand description

A view that bridges the gap between impl View and impl View<T>.

ยงExample

fn opaque_view() -> impl View {
    button(text!("I am a button!"))
}

fn data_view<T>() -> impl View<T> {
    opaque(opaque_view())
}