Skip to main content
Version: 3.x

withSequence

withSequence is an animation modifier that lets you run animations in a sequence.

Loading...

Reference

import { withSequence } from 'react-native-reanimated';

function App() {
sv.value = withSequence(withTiming(50), withTiming(0));
// ...
}

Type definitions

type AnimatableValue = number | string | number[];

function withSequence<T extends AnimatableValue>(...animations: [T, ...T[]]): T;

Arguments

...animations

Any number of animation objects to be run in a sequence.

Returns

withSequence returns an animation object. It can be either assigned directly to a shared value or can be used as a value for a style object returned from useAnimatedStyle.

Example

Loading...

Platform compatibility

AndroidiOSWeb