我正在尝试添加<Image>一个<MapView>.应该看起来像这样 -
这是我的代码 -
<MapView
mapType='standard'
style={styles.map}
region={{
latitude: selectedLoc.location.latitude,
longitude: selectedLoc.location.longitude,
latitudeDelta: 0.005,
longitudeDelta: 0.005
}}
onRegionChange={() => { } }
onRegionChangeComplete={() => { } }
showsUserLocation={false}
zoomEnabled={false}
draggable={false}
annotations={[{
longitude: selectedLoc.location.latitude,
latitude: selectedLoc.location.longitude,
title: selectedLoc.title
}]}
initialRegion={{
latitude: selectedLoc.location.latitude,
longitude: selectedLoc.location.longitude
}}>
<Image
style={{
width: 50,
height: 50,
}}
resizeMode={"contain"}
source={{ uri: 'https://unsplash.it/50/50/?random' }}
/>
</MapView>
Run Code Online (Sandbox Code Playgroud)
我从这段代码中找不到任何视图.请告诉我
如何在React Native for iOS(Xcode)中设置调试或发布模式,就像我们在Build Setting-> LLVM Preprocessor over Native code中所做的那样?有什么办法或者我需要在JS代码中指定吗?如果没有办法,那么我们应该如何在React Native JS Code中访问Xcode设置的属性?
最近我在iOS应用中添加了插页式广告.虽然在开发阶段我们应该使用testDevice id来测试广告.google admob faq说你可以提交带有testDevice id代码的应用程序.我确实提交了这个.我的应用会在商店上发布真实广告吗?