i got a problem with link url,
the url is showing in page component but can't clicking or directing open browser
how to solve this issue?
Please show us your code, we can't help you with so little information.
<Container style={{paddingLeft: 10, paddingRight:10, flex: 1}}>
<HTML html={this.state.data.htmlcontent} imagesMaxWidth={win}/>
</Container>
this is my code , App get html content from API ,
content html include tag link <a href ... >downlad</a>
but url link download cant clicking...
thanks
Nothing wrong with that code, please copy/paste the HTML you're rendering.
You probably want to take a look at : onLinkPress
You can implement it such as : onLinkPress: (evt, href) => { Linking.openURL(href); }
@LouisJS Oh.. Thanks work it..
I asked myself the same question. Thanks.
So for others: Linking is not default, if there are <a...> in your HTML, you have to implement onLinkPress.
How does one "implement onLinkPress?
Answered my own question by looking at the demo here: https://goo.gl/ewkqXx
You probably want to take a look at :
onLinkPress
You can implement it such as :onLinkPress: (evt, href) => { Linking.openURL(href); }
import {Linking } from 'react-native';
Implement link in react native render Html complete example
https://infinitbility.com/how-to-open-any-link-from-react-native-render-html
Most helpful comment
You probably want to take a look at :
onLinkPressYou can implement it such as :
onLinkPress: (evt, href) => { Linking.openURL(href); }