map.panTo Example

map.panTo
Show animated panning effects in the map
This is an example of transition effects. If the new random center is in the current extent, the map will pan smoothly.
The random selection will continue until you press it again. Additionally, you can single click in the map to pan smoothly to that area, or use the pan control to pan smoothly.