Trying to understand apply()
a little better. I think this a great use case, it just doesn't work.
I'm getting this error:
Uncaught TypeError: function apply() { [native code] } is not a constructor
When I try to apply to google.maps.LatLng
new google.maps.LatLng.apply(null, hospital)
or
new google.maps.LatLng().apply(null, hospital)
Update
This works
new google.maps.LatLng.apply(40.670287895547006,-73.9865255355835)
This fails
new google.maps.LatLng.apply(null, [40.670287895547006,-73.9865255355835])