-
Notifications
You must be signed in to change notification settings - Fork 0
/
App.js
60 lines (47 loc) · 1.11 KB
/
App.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
import React from 'react';
import { StyleSheet, View, Text, Dimensions, TouchableOpacity } from 'react-native';
import { GoogleMapsApp } from './src/maps/google-maps'
const { width, height } = Dimensions.get('window');
const ASPECT_RATIO = width / height;
const LATITUDE = 37.78825;
const LONGITUDE = -122.4324;
const LATITUDE_DELTA = 0.0922;
const LONGITUDE_DELTA = LATITUDE_DELTA * ASPECT_RATIO;
const SPACE = 0.01;
class App extends React.Component {
constructor(props) {
super(props);
this.state = {
region: {
latitude: LATITUDE,
longitude: LONGITUDE,
latitudeDelta: LATITUDE_DELTA,
longitudeDelta: LONGITUDE_DELTA,
},
mapSelected: 'google'
}
this.modal = null
}
render() {
return (
<View style={styles.container}>
<GoogleMapsApp />
</View>
);
}
componentDidMount = () => {
setTimeout(() => {
this.forceUpdate()
}, 100)
}
}
const styles = StyleSheet.create({
container: {
alignItems: 'center',
flex: 1
},
map: {
...StyleSheet.absoluteFillObject,
}
});
export default App;