Skip to content

Commit cbffb12

Browse files
committed
update example with latest RN
1 parent 00a5662 commit cbffb12

File tree

3 files changed

+288
-445
lines changed

3 files changed

+288
-445
lines changed

example/Btn.js

Lines changed: 7 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,7 @@
11
//@flow
2-
import React, {
3-
Component,
4-
PropTypes,
5-
} from "react";
6-
import {
7-
Text,
8-
TouchableOpacity,
9-
StyleSheet,
10-
} from "react-native";
2+
import React, { Component } from "react";
3+
import PropTypes from "prop-types";
4+
import { Text, TouchableOpacity, StyleSheet } from "react-native";
115

126
const styles = StyleSheet.create({
137
root: {
@@ -17,22 +11,20 @@ const styles = StyleSheet.create({
1711
color: "#36f",
1812
borderWidth: 1,
1913
borderColor: "#36f",
20-
fontSize: 12,
14+
fontSize: 12
2115
}
2216
});
2317

2418
export default class Btn extends Component {
2519
static propTypes = {
2620
onPress: PropTypes.func.isRequired,
27-
label: PropTypes.string.isRequired,
21+
label: PropTypes.string.isRequired
2822
};
29-
render () {
23+
render() {
3024
const { onPress, label } = this.props;
3125
return (
3226
<TouchableOpacity onPress={onPress}>
33-
<Text style={styles.root}>
34-
{label}
35-
</Text>
27+
<Text style={styles.root}>{label}</Text>
3628
</TouchableOpacity>
3729
);
3830
}

example/package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,12 @@
88
"ios": "react-native run-ios"
99
},
1010
"dependencies": {
11-
"gl-react": "^2.2.10",
11+
"gl-react": "^2.3.1",
1212
"gl-react-native": "^2.47.0",
1313
"lodash": "4.17.4",
14-
"react": "16.0.0-alpha.12",
15-
"react-native": "^0.47.0",
14+
"prop-types": "^15.6.0",
15+
"react": "^16.0.0",
16+
"react-native": "^0.49.0",
1617
"react-native-maps": "^0.16.2",
1718
"react-native-svg": "^5.4.1",
1819
"react-native-svg-uri": "github:gre/react-native-svg-uri#onLoad",

0 commit comments

Comments
 (0)