React-native (iv)--listview Navigator.push
1. Must be added when using Nav
Touchablehighlight,
Navigatorios;
var {
appregistry,
StyleSheet,
Text,
View,
Navigatorios,
touchablehighlight,
} = React;
Nav must have a rootview when used, which is basically the same as iOS, which is used as follows:
-(Instancetype) Initwithrootviewcontroller: (Uiviewcontroller *) Rootviewcontroller
React-native is used as follows:
<navigatorios Style={style.container}
tintcolor={' #333344 '}
initialroute={{
title: ' Flicker ',
Component:require ('./app/views/home/home ')
}}
Itemwrapperstyle={style.navigator}/>
2, push Use this is not the same as iOS, iOS use the following methods can be implemented:
-(void) Pushviewcontroller: (Uiviewcontroller *) Viewcontroller animated: (BOOL) animated
React-native must use Touchablehighlight mates with the following code:
<touchablehighlight onpress={() = This.showdetail (rsustlbody)} >
<view style={styles.container} >
<image
source={{uri:rsustlbody.otherinfo.productimg}}
style={styles.thumbnail}
/>
<view style={styles.rightcontainer}>
<text style={styles.title}>{rsustlbody.name}</text >
<text style={styles.year}>{rsustlbody.brokercommissionrate}</text>
</View>
</View>
</TouchableHighlight>
When using touchablehighlight, there must be a view