UNPKG

558 BTypeScriptView Raw
1import { Animated } from 'react-native';
2/**
3 * Use an Animated Node based on a condition. Similar to Reanimated's `cond`.
4 *
5 * @param condition Animated Node representing the condition, must be 0 or 1, 1 means `true`, 0 means `false`
6 * @param main Animated Node to use if the condition is `true`
7 * @param fallback Animated Node to use if the condition is `false`
8 */
9export default function conditional(condition: Animated.AnimatedInterpolation, main: Animated.AnimatedInterpolation, fallback: Animated.AnimatedInterpolation): Animated.AnimatedAddition;