Search code snippets, questions, articles...

React Native Map Fit To Cordinates

const MapFitToCordinates = () => {
  map.current.fitToCoordinates(
    [
      {latitude: location.latitude, longitude: location.longitude},
      {latitude: location.latitude, longitude: location.longitude},
    ],
    {
      edgePadding: {
        edgePadding: DEFAULT_PADDING,
        animated: true,
      },
    },
  );
};
Was this helpful?
0 Comments
Programming Feeds
Learn something new everyday on Devsheet