setBearing method

MapboxMap setBearing(
  1. num bearing, [
  2. dynamic eventData
])

Sets the map's bearing (rotation). The bearing is the compass direction that is "up"; for example, a bearing of 90° orients the map so that east is up.

Equivalent to jumpTo({bearing: bearing}).

@memberof MapboxMap# @param bearing The desired bearing. @param eventData Additional properties to be added to event objects of events triggered by this method. @fires movestart @fires moveend @returns {MapboxMap} this @example // rotate the map to 90 degrees map.setBearing(90);

Implementation

MapboxMap setBearing(num bearing, [dynamic eventData]) =>
    MapboxMap.fromJsObject(jsObject.setBearing(bearing));