Skip to content

Conversation

Crash--
Copy link

@Crash-- Crash-- commented Nov 14, 2016

Needed if you want to display an svgUri inside a TouchableHighlight

@henrikra
Copy link
Contributor

henrikra commented Nov 14, 2016

Here is component where I use svg-uri inside of TouchableHighlight https://github.com/henrikra/pokkaPeuta/blob/master/src/components/WeatherReportItem.js and I don't have any problems :O

@Crash--
Copy link
Author

Crash-- commented Nov 14, 2016

does

<TouchableHighlight onPress={() => console.log('pressed')}>
 <SvgUri width="75" height="75" source={require('../img/test.svg')} />
</TouchableHighlight>

Works for you without this commit?

It seems that TouchableOpacity has a specific behavior https://facebook.github.io/react-native/docs/direct-manipulation.html#setnativeprops-with-touchableopacity

@henrikra
Copy link
Contributor

image
Yes it does

@Crash--
Copy link
Author

Crash-- commented Nov 14, 2016

It does with TouchableOpacity, but with TouchableHighlight ?

@GopiKrishna10
Copy link

@henrikra , If i am trying to import react-native-svg-uri. It throws some error like module not found. following are the node_module versions we are using.
"react": "15.3.1",
"react-native": "^0.39.0",
"react-native-svg": "^4.3.1",
"react-native-svg-uri": "^1.2.1"
Can you please help me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants