Function freya::components::VirtualScrollView
pub fn VirtualScrollView<T, 'a>(
cx: &'a Scoped<'a, VirtualScrollViewProps<'a, T>>
) -> Option<VNode<'a>>
Expand description
VirtualScrollView
component.
Props
Example
fn app(cx: Scope) -> Element {
render!(
VirtualScrollView {
width: "100%",
height: "100%",
show_scrollbar: true,
length: 5,
item_size: 80.0,
builder_values: (),
direction: "vertical",
builder: Box::new(move |(k, i, _, _)| {
rsx! {
label {
key: "{k}",
height: "80",
"Number {i}"
}
}
})
}
)
}