reactjs - 在 ReactNative 中显示从 sqlite blob 加载的图像
问题描述
下面是我的实现
return (
<View key={page.ItemID} collapsable={false}>
<Image
style={{ width: 100, height: 100 }}
source={{uri: URL.createObjectURL(new Blob(blobData, {type: "image/png"}))}}
/>
<Text>Test</Text>
</View>
);
运行后出现错误npx react-native run-ios
,详细在这里:
undefined is not a function (near '...parts.map...')
解决方案
我请求,请检查您作为 uri 提供的值。你可以来知道是什么问题。
结帐下面的链接以获取您可以提供的 uri 的可能值。 https://reactnative.dev/docs/image#source
推荐阅读
- computer-science - double 的小数部分是多少位?
- c# - 如何在 Xamarin.iOs 上使用 PaymentIntent 触发 3DSecure?
- javascript - 在 V-Data-Table 中隐藏/显示多列
- react-native - 如何编辑 TextInput 的值
- xamarin - Xamarin Frame 只有一个圆角
- matlab - 如何在 Matlab 实时脚本编辑器中显示生成的乳胶表达式?
- sql - Django找到多对多关系的完全匹配
- flutter - 如何在 Flutter 中将颜色转换为字符串?
- histogram - Google 地球引擎中的直方图输出
- php - 无论如何在WordPress中格式化我的端点URL?