I have been struggling with how to determine the visible map bounds within the page. I require this ability in order to determine the area to search for markers within from a backend location service. I've tried several approaches to get to the underlying google API which appears to support my use case.
mounted() {
const map = this.$refs.myMap
console.log('myMap: ', Object.keys(map))
const gMap = map.getBounds()
console.log('bounds: ', gMap)
},
The first log prints multiple available keys, one being the getBounds() function. However, calling getBounds() returns undefined.
Please advise. Thanks.
I have been struggling with how to determine the visible map bounds within the page. I require this ability in order to determine the area to search for markers within from a backend location service. I've tried several approaches to get to the underlying google API which appears to support my use case.
The first log prints multiple available keys, one being the
getBounds()function. However, callinggetBounds()returnsundefined.Please advise. Thanks.