Restricting Map Bound
GeFeSTTS opened this issue · comments
Oleksii Domianych commented
Is it possible to set restrict map bound (https://developers.google.com/maps/documentation/javascript/examples/control-bounds-restriction#maps_control_bounds_restriction-javascript) in this library? I tried different ways to block removal from center, but it doesn't work.
const GoogleMaps = withScriptjs(
withGoogleMap(({institutes}) => (
<GoogleMap
defaultOptions={{
fullscreenControl: false,
mapTypeControl: false,
streetViewControl: false,
center: CENTER,
zoom: 12,
restriction: {
latLngBounds: CENTER,
strictBounds: false,
},
}}
>
{institutes.map((institute, index) =>
renderMarker(institute, index)
)}
</GoogleMap>
))
);
Alexey Lyakhov commented
@GeFeSTTS this package is unmaintained over 4 years. please use @react-google-maps/api instead.