import * as React from 'react';
import { Animated, Button, View } from 'react-native';
import {
createStackNavigator,
NavigationStackScreenProps,
CardAnimationContext,
} from 'react-navigation-stack';
const ListScreen = (props: NavigationStackScreenProps) => (
);
const AnotherScreen = () => (
{value => {
const scale = value
? value.current.progress.interpolate({
inputRange: [0, 1],
outputRange: [0.25, 1],
})
: 1;
return (
Animates on progress
);
}}
);
const YetAnotherScreen = () => (
{value => (
Disappears when swiping
)}
{value => (
Disappears only when closing
)}
);
export default createStackNavigator(
{
List: ListScreen,
Another: AnotherScreen,
YetAnother: YetAnotherScreen,
},
{ initialRouteName: 'List' }
);