image - 当我在渲染 HTML 后按下它时,不要在浏览器中显示图像
问题描述
在反应应用程序中,我必须呈现一些包含文本、链接和一些图像/视频的 html 代码。
我为此使用 react-native-render-html 。
有一种方法可以让链接通过 WebView 打开,但没有图像?
<View style={styles.testo_a}>
<HTML html={this.state.text_}
onLinkPress= {(evt, href) => { <WebView source={{href}});/>}}
ignoredStyles={['width']}
staticContentMaxWidth={Dimensions.get('window').width-10}
imagesMaxWidth={Dimensions.get('window').width-10}/>
</View>
解决方案
推荐阅读
- python - 如何使用 python 访问相机?
- angular - 在根服务初始化之前分配一个令牌
- javascript - Javascript Regex,如果没有,则在数学运算符前后添加空格
- python - 我正在尝试制作一个程序来显示美元价值,但我无法让它向我打印我想要的信息
- identityserver4 - Identityserver4 使用两个相同的外部提供者,第二个外部提供者登录总是失败
- javascript - Javascript动态删除重复的innerHTMLs
- python - Python 使用 psycopg2 设置为 postgres 数组
- android - 如何将数组传递到更高的范围
- html - CSS 无法生成下拉菜单链接
- c - 计算字符串中的子字符串字符