0
我在我的這個React Native代碼中,我試圖解析一些API數據。React Native中的相鄰JSX - 錯誤
{this.state.articles.map(article => (
<Image
style={{width: 50, height: 50}}
source={{uri: article.urlToImage}}
/>
<Text style={styles.article} onPress={() => Linking.openURL(article.url)} >{article.title}</Text>
我每次運行它的時候,我得到的是說,一個錯誤:
Adjacent JSX elements must be wrapped in an enclosing tag
我不知道該怎麼辦,誰能幫幫我嗎?謝謝!