I have a TouchableOpacity nested inside SVG element create by using react-native-svg
library. It looks something like this:
<Svg
width="100%"
height="100%"
top="0%"
left="0%"
viewBox="0 0 828 828"
>
(...)
<TouchableOpacity onPress={this.handleClick}>
<Text>Button!</Text>
</TouchableOpacity>
(...)
</Svg>
Where handleClick is not triggered. I have different implementation for the same feature for Android where TouchableOpacity is outside Svg
element and onPress
is correctly triggered. Has anyone encountered this issue and found a solution? Placing this outside for iOS is not an option, unfortunately.
Used react-native-svg
version is 7.0.3
Thanks!