Quantcast
Channel: Active questions tagged react-native+ios - Stack Overflow
Viewing all articles
Browse latest Browse all 16750

onPress does not redirect to screen on ios

$
0
0

I've got a bunch of tiles (rectangles) I've created. On android it seems that when I click on the title the onPress function works as expected. But on iOS when I click the tile it doesn't work? is there something I have to do differently when it comes to onPress()?

   const Container = styled(BackgroundImage)`        aspectRatio:1.32;        alignItems:center;        justifyContent:center;        background: ${Colors.Black};        borderRadius: 10px;        width:100%;    `    const Heading = styled(TextBold)`        color:${Colors.White};        width:100%;        textAlign:center;        textAlignVertical:center;    `    const CategoryTile = (props: { venueType: VenueType, onPress: () => void }) =>        (<Container imageStyle={{ borderRadius: 10, opacity: 0.5 }} uri={props.venueType.imageUrl}><Heading onPress={props.onPress} text={props.venueType.name} numberOfLines={1} /></Container>)

Viewing all articles
Browse latest Browse all 16750

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>