Skip to content

Commit 63bdc08

Browse files
committed
update example with render usage
1 parent 2b91507 commit 63bdc08

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

Example/Main.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,11 @@ export default class main extends Component {
3434
</TouchableOpacity>
3535
);
3636
}
37+
renderImage(props) {
38+
return (
39+
<Image style={props.imageStyle} source={{ uri: props.imageSrc }} />
40+
);
41+
}
3742
render() {
3843
return (
3944
<View style={styles.container}>
@@ -48,6 +53,8 @@ export default class main extends Component {
4853
onClose={data => this.handleClose(data)}
4954
onCancel={data => this.handleCancel(data)}
5055
imageSrc={'https://facebook.github.io/react-native/docs/assets/favicon.png'}
56+
renderImage={(props) => this.renderImage(props)}
57+
renderCancel={(props) => this.renderImage(props)}
5158
/>
5259
</View>
5360
);

0 commit comments

Comments
 (0)