I placed two markers on a Google map. One is in the USA, and the other is somewhere in Asia. Google only provides zoom levels of 1, 2, 3, 4, 5, 6, etc.
I do not want to hard code the zoom level. How can I display all markers based on distance? That is, if two elements are very close to each other or in the same city, a close zoom level should be used, and if they are far from each other, then the maximum zoom level should be used.
source
share