Function freya::components::GestureArea

pub fn GestureArea<'a>(
    cx: &'a Scoped<'a, GestureAreaProps<'a>>
) -> Option<VNode<'a>>
Expand description

GestureArea component.

Props

See GestureAreaProps.

Example

fn app(cx: Scope) -> Element {
   let gesture = use_state(cx, || "Tap here".to_string());
   render!(
       GestureArea {
           ongesture: move |g| gesture.set(format!("{g:?}")),
           label {
               "{gesture}"
           }
       }
   )
}