Function zng::data_context::data
source · pub fn data<T>(child: impl UiNode, data: impl IntoVar<T>) -> impl UiNodewhere
T: VarValue,
Expand description
P
Data context.
Sets the DATA
context for this widget and descendants, replacing the parent’s data.
Note that only one data context can be set at a time, the data
will override the parent’s
data even if the type T
does not match.