Skip to main content

use_keyframes

Function use_keyframes 

Source
pub fn use_keyframes<T>(
    builder: impl FnOnce(KeyframeTrack<T>) -> KeyframeTrack<T>,
) -> (Signal<T>, KeyframeHandle<T>)
where T: Animatable + Send + Sync + 'static,
Expand description

Create a signal-backed keyframe track hook.

The builder must insert at least one keyframe. Empty tracks are ambiguous because there is no fallback value for the returned Signal<T>.