import * as React from 'react'; import MapView, { Marker } from 'react-native-maps'; import { StyleSheet, Text, View, Dimensions, Pressable } from 'react-native'; export default function Map() { const [pin, setPin] = React.useState({ latitude: 18.4655, longitude: -66.1057, }) return ( { setPin({ latitude: e.nativeEvent.coordinate.latitude, longitude: e.nativeEvent.coordinate.longitude })}} provider="google" > ); } const styles = StyleSheet.create({ container: { flex: 1, backgroundColor: '#fff', alignItems: 'center', justifyContent: 'center', }, map: { width: Dimensions.get('window').width, height: Dimensions.get('window').height, }, });