--- layout: api title: v0.6.5 categories: api navigation: version: v0.6.5 navigation: - title: mapbox.map items: - map.smooth - map.center - map.zoom - map.centerzoom - map.getExtent - map.setExtent - map.setZoomRange - map.setPanLimits - map.setSize - map.zoomBy - map.zoomByAbout - map.panBy - map.draw - map.requestRedraw - map.refresh - Separator: Properties - map.coordinate - map.dimensions - map.parent - Separator: Conversions - map.pointLocation - map.pointCoordinate - map.locationPoint - map.locationCoordinate - map.coordinatePoint - map.coordinateLocation - Separator: Layer management - map.addLayer - map.addTileLayer - map.removeLayer - map.removeLayerAt - map.disableLayer - map.disableLayerAt - map.enableLayer - map.enableLayerAt - map.getLayer - map.getLayers - map.getLayerAt - Separator: Easing - map.ease - Separator: User interface - map.ui - map.ui.fullscreen - map.ui.hash - map.ui.zoombox - map.ui.zoomer - map.ui.attribution - map.ui.legend - map.ui.pointselector - map.ui.boxselector - map.ui.refresh - Separator: Interaction - map.interaction - map.interaction.auto - map.interaction.refresh - Separator: Events - map.addCallback - map.removeCallback - Event "zoomed" - Event "panned" - Event "resized" - Event "extentset" - Event "drawn" - title: mapbox.load items: - title: mapbox.auto items: - title: mapbox.layer items: - layer.id - layer.named - layer.url - layer.tilejson - layer.composite - layer.parent - title: mapbox.markers.layer items: - markers.named - markers.factory - markers.features - markers.add_feature - markers.sort - markers.filter - markers.key - markers.url - markers.id - markers.csv - markers.extent - markers.addCallback - markers.removeCallback - markers.markers - title: mapbox.markers.interaction items: - interaction.remove - interaction.add - interaction.hideOnMove - interaction.showOnHover - interaction.exclusive - interaction.formatter - title: mapbox.ease items: - ease.map - ease.from - ease.to - ease.zoom - ease.optimal - ease.location - ease.t - ease.future - ease.easing - ease.path - ease.run - ease.running - ease.stop ---

Map

Maps are the central element of the Javascript API - the map object manages tile layers, contains UI elements, and provides many types of interactivity.

mapbox.map(element [, layers] [, dimensions] [, eventHandlers])

Create a map on the current page.

Arguments:

Returns a map object, which has the following methods:

Example:

// for this to work, you'll need an element like
// <div id="map"></div> on your page
var map = mapbox.map('map');

map.smooth(value)

Enable or disable inertial panning on maps. By default, maps smoothly pan and zoom with inertia.

Arguments:

Returns the map object.

Example:

map.smooth(false); // disable inertial panning

map.center(centerpoint [, animate])

Center the map on a geographical location, or get its current center.

Arguments:

Returns the map object if arguments are given, the map's center location (in the same form as specified in centerpoint) otherwise.

Example:

// center the map on Manhattan
map.center({ lat: 40.74, lon: -73.98);

map.zoom(zoom [, animate])

Set the map's zoom level, or get its current zoom level.

Arguments:

Returns the map object if arguments are given, the map's current zoom level otherwise.

Example:

// zoom to z10 and animate the transition
map.zoom(10, true);

map.centerzoom(center, zoom [, animate])

Set the map's zoom level and centerpoint simultaneously. Especially with the third argument, animate, set to true, this allows for a better animation effect.

Arguments:

Returns the map object.

Example:

// Center the map on Washington, DC, at zoom level 5
map.centerzoom({ lat: 38.9, lon: -77.03 }, 5);

map.getExtent()

Get the extent of the currently visible area.

Returns an instance of MM.Extent.

map.setExtent

Modify the center and zoom of the map so that the provided extent is visible. This can be useful because extents - the corners of the map - can implicitly cause the map to 'show the whole world' regardless of screen size.

Arguments:

Returns the map object.

Example:

// using an extent object:
map.setExtent(new MM.Extent(80, -170, -70, 170));
// this call can also be expressed as:
map.setExtent([{ lat: 80, lon: -170 }, { lat: -70, lon: 170 }]);

map.setZoomRange(minZoom, maxZoom)

Set the map's minimum and maximum zoom levels.

Arguments:

Returns the map object.

Example:

map.setZoomRange(3, 17);

map.setPanLimits(locations)

Set the map's panning limits.

Arguments:

Returns the map object.

Example:

map.setPanLimits([{ lat: -20, lon: 0 }, { lat: 0, lon: 20 }]);
// or with an Extent object
map.setPanLimits(new MM.Extent(0, -20, -20, 0));

map.setSize(dimensions)

Set the map's dimensions. This sets map.autoSize to false to prevent further automatic resizing.

Arguments:

Returns the map object.

map.zoomBy(zoomOffset)

Change zoom level by the provided offset.

Arguments:

Returns the map object.

Example:

// zoom in by one zoom level
map.zoomBy(1);
// zoom out by two zoom levels
map.zoomBy(-2);

map.zoomByAbout(zoomOffset, point)

Change the zoom level by the provided offset, while maintaining the same location at the provided point. This is used by MM.DoubleClickHandler.

Returns the map object.

map.panBy(x, y)

Pan by the specified distances.

Arguments:

Returns the map object.

Example:

// pan right and down by one pixel
map.panBy(1, 1);

map.draw()

Redraw the map and its layers. First, the map enforces its coordLimits on its center and zoom. If autoSize is true, the map's dimensions are recalculated from its parent. Lastly, each of the map's layers is drawn.

map.requestRedraw()

Request a "lazy" call to draw in 1 second. This is useful if you're responding to lots of user input and know that you'll need to redraw the map eventually, but not immediately.

map.refresh()

Refreshes map.ui and map.interaction to reflect any layer changes.

Properties

map.coordinate

The map's current center coordinate.

map.dimensions

An object with x and y attributes expressing the dimensions of the map in pixels.

map.parent

The DOM element containing the map.

Conversions

map.pointLocation(point)

Convert a screen point to a location (longitude and latitude).

Arguments:

Returns an object with lat and lon properties indicating the latitude and longitude of the point on the globe.

Example:

// get the geographical location of the top-left corner of the map
var top_left = map.pointLocation({ x: 0, y: 0});

map.pointCoordinate(point)

Convert a screen point to a tile coordinate.

Arguments:

Returns an instance of MM.Coordinate - an object with column, row, and zoom properties indicating the coordinate of the point. The zoom of the point will be same as the current zoom level of the map.

Example:

// get the coordinate location of the top-left corner of the map
var top_left = map.coordinateLocation({ x: 0, y: 0});

map.locationPoint(location)

Convert a location to a screen point.

Arguments:

Returns an instance of MM.Point.

map.locationCoordinate(location)

Convert a location to a tile coordinate.

Arguments:

Returns an instance of MM.Coordinate.

map.coordinatePoint(coordinate)

Convert a tile coordinate to a screen point.

Arguments:

Returns an instance of MM.Point.

map.coordinateLocation(coordinate)

Convert a tile coordinate to a location (longitude and latitude).

Arguments:

Returns and instance of MM.Location.

Layer management

map.addLayer(layer)

Add a layer to the map, above other layers.

Arguments:

Returns the map object.

Example:

// add a layer to the map
map.addLayer(mapbox.layer().id('examples.map-dg7cqh4z'));

map.addTileLayer(layer)

Add a tile layer to the map, below any marker layers to prevent them from being covered up.

Returns the map object.

map.removeLayer(layer)

Remove the provided layer from the map.

Arguments:

Returns the map object.

map.removeLayerAt(index)

Remove the layer at the provided index.

Returns the map object.

map.disableLayer(layer)

Disable a layer. Disabled layers maintain their position, but do not get drawn.

Arguments:

Returns the map object.

map.disableLayerAt(index)

Disable a layer at the provided index. Disabled layers maintain their position, but do not get drawn.

Arguments:

Returns the map object.

Example:

// disable the topmost layer in the map
map.disableLayerAt(0);

map.enableLayer(layer)

Enable a previously disabled layer.

Arguments:

Returns the map object.

map.enableLayerAt(index)

Enable the layer at the provided index.

Arguments:

Returns the map object.

map.getLayer(name)

Get a layer by name.

Arguments:

Returns the layer object.

map.getLayers()

Returns a list the map's layers.

map.getLayerAt(index)

Get the layer at the provided index.

Arguments

Returns a layer.

Easing

map.ease

This is an instance of mapbox.ease attached to the map for convenience. For full documentation take a look at mapbox.ease.

Example:

map.ease.location({ lat: 10, lon: -88 }).zoom(5).optimal();
User interface

map.ui

The API provides a set of UI elements that can be freely mixed & matched, as well as styled beyond the default (provided in the mapbox.css stylesheet). Maps created with mapbox.map have an array of pre-initialized UI elements at .ui. All UI elements support the simple operations .add() and .remove() to add & remove them from the map.

.add()

Add the UI element to the map. Add the HTML elements that the UI element manages (if any) to the map element, and bind any events.

Example:

// enable the zoomer control. adds + and - buttons to the map
map.ui.zoomer.add();

.remove()

Remove the UI element from the map. Removes the HTML elements from the map, if any, and removes listeners, if any.

// remove the fullscreen control from the map visually and functionally
map.ui.fullscreen.remove();

.element()

For applicable elements (zoomer, attribution, legend, fullscreen), returns the DOM element this control exposes.

map.ui.fullscreen

Add a link that can maximize and minimize the map on the browser page

DOM Structure:

<a class="map-fullscreen" href="#fullscreen">fullscreen</a>

map.ui.hash

Add the map's changing position to the URL, making map locations linkable

map.ui.zoombox

Add the ability to zoom into the map by shift-clicking and dragging a box, to which the map zooms

map.ui.zoomer

Add zoom in and zoom out buttons to map

DOM Structure:

<!-- when a zoom control is inactive, .zoomdisable is added to it -->
<a href="#" class="zoomer zoomin">+</a>
<a href="#" class="zoomer zoomout">-</a>

map.ui.attribution

Add an element with attribution information to the map

DOM Structure:

<div class="map-attribution map-mm"></div>

map.ui.legend

Add an element with legend information to map

DOM Structure:

<div class="map-legends">
    <div class="map-legend">
        <!-- Legend content -->
    </div>
</div>

map.ui.pointselector

Allow simple location selection on the map: clicking without dragging will select a point, and notify listeners with the new list of points.

pointselector.addCallback(event, callback)

Adds a callback that is called on changes to the pointselector contents.

Arguments:

Event should be a String which is one of the following:

Callback is a Function that is called with arguments depending on what event is bound:

Returns the pointselector

pointselector.removeCallback(event, callback)

Remove a callback bound by .addCallback(event, callback).

Arguments:

Returns the pointselector

map.ui.boxselector

Allow extents to be selected on the map.

boxselector.addCallback(event, callback)

Adds a callback that is called on changes to the boxselector contents.

Arguments:

Event should be a String which is one of the following:

Callback is a Function that is called with arguments depending on what event is bound:

Returns the boxselector

boxselector.removeCallback(event, callback)

Remove a callback bound by .addCallback(event, callback).

Arguments:

Returns the boxselector

map.ui.refresh()

Refresh legend and attribution to reflect layer changes, merging and displaying legends and attribution for all enabled layers.

Returns the ui object.

Interaction

map.interaction

Interaction is what we call interactive parts of maps that are created with the powerful tooltips & regions system in TileMill. Under the hood, it's powered by the open UTFGrid specification.

map.interaction.auto()

Enable default settings - animated tooltips - for interaction with the map. This internally calls interaction.refresh() to set the interactivity for the top layer.

Returns the interaction control

Example:

var interaction = mapbox.interaction()
    .map(map)
    .auto();

DOM Structure (tooltips):

<div class="map-tooltip map-tooltip-0">
    <!-- Tooltip content -->
</div>

map.interaction.refresh()

Refresh interactivity control to reflect any layer changes. If auto has not been called, this function will not change anything.

Returns the interaction control

Events

map.addCallback(event, callback)

Add a callback for a specific event type. Event types are listed further down.

Arguments:

Returns the map object.

map.removeCallback(event, callback)

Remove a previously added callback.

Arguments:

Returns the map object.

Event: zoomed

Fires when the map's zoom level changes. Callbacks receive two arguments:

Example:

map.addCallback("zoomed", function(map, zoomOffset) {
    console.log("Map zoomed by", zoomOffset);
});

Event: panned

Fires when the map has been panned. Callbacks receive two arguments:

Example:

map.addCallback("panned", function(map, panOffset) {
    console.log("map panned by x:", panOffset[0], "y:", panOffset[1]);
});

Event: resized

Fires when the map has been resized. Callbacks receive two arguments:

Example:

map.addCallback("resized", function(map, dimensions) {
    console.log("map dimensions:", dimensions.x, "y:", dimensions.y);
});

Event: extentset

Fires when the map's extent is set. Callbacks receive two arguments:

Example:

map.addCallback("extentset", function(map, extent) {
    console.log("Map's extent set to:", extent);
});

Event: drawn

Fires when the map is redrawn. Callbacks receive one argument:

Example:

map.addCallback("drawn", function(map) {
  console.log("map drawn!");
});

Loading Utilities

To load information about a certain map you've created on MapBox, we provide mapbox.load and mapbox.auto, which pull the TileJSON file from a server and auto-instantiate many of its features.

mapbox.load(url, callback)

Load layer definitions and other map information from MapBox Hosting.

Arguments:

Example:

<div id='map' style='width:500px;height:400px;'></div>
<script>
mapbox.load('tmcw.map-hehqnmda', function(o) {
    var map = mapbox.map('map');
    map.addLayer(o.layer);
});
</script>

mapbox.auto(element, url [, callback])

Load and create a map with sensible defaults.

Arguments:

Returns undefined: this is an asynchronous function without a useful return value.

Example:

<div id='map' style='width:500px;height:400px;'></div>
<script>
mapbox.auto('map', 'http://a.tiles.mapbox.com/v3/tmcw.map-hehqnmda.jsonp');
</script>

Layer

mapbox.layer is a fast way to add layers to your map without having to deal with complex configuration.

mapbox.layer()

You can add a tiled layer to your map with mapbox.layer(), a simple interface to layers from MapBox Hosting and elsewhere.

Returns a layer object, which has the following methods:

layer.id(id, callback)

Get or set the layer ID, which corresponds to a MapBox map.

Arguments:

Returns the layer object if arguments are given, the layer's id otherwise.

Example:

var layer = mapbox.layer().id('map-hehqnmda');

layer.named([name])

Get or set the name of the layer, as referred to by the map.

Arguments:

Returns the layer object if arguments are given, the layer's name otherwise.

layer.url([url, callback])

Pull a layer from a server besides MapBox Hosting that supports TileJSON, like a self-hosted TileStream.

Arguments:

Returns the layer object if arguments are given, the pulled URL otherwise.

Example:

var layer = mapbox.layer().url('http://a.tiles.mapbox.com/v3/tmcw.map-hehqnmda.jsonp');

layer.tilejson([tilejson])

Set layer options directly from a TileJSON object.

Arguments:

Returns the layer object if arguments are given, the layer's TileJSON settings otherwise.

layer.composite(enabled)

Enable or disable compositing layers together on MapBox hosting. Compositing combines multiple tile images into one layer of blended images, increasing map performance and reducing the number of requests the browser needs to make.

Returns the layer object.

layer.parent

The layer's parent DOM element.

Markers layer

mapbox.markers is a markers library that makes it easier to add HTML elements on top of maps in geographical locations and interact with them. Internally, markers are stored as GeoJSON objects, though interfaces through CSV and simple Javascript are provided.

mapbox.markers.layer()

mapbox.markers.layer() creates a new layer into which markers can be placed and which can be added to a map with map.addLayer()

markers.named([name])

Set the name of this markers layer. The default name for a markers layer is 'markers'

Arguments:

Returns the layer object if a new name is provided, otherwise the layer's existing name if it is omitted.

markers.factory([factoryfunction])

Define a new factory function, and if the layer already has points added to it, re-render them with the new factory. Factory functions are what turn GeoJSON feature objects into HTML elements on the map. Due to the way that markers allows multiple layers of interactivity, factories that want their elements to be interactive must either set .style.pointerEvents = 'all' on them via Javascript, or have an equivalent CSS rule with pointer-events: all that affects the elements.

Arguments:

Returns the layer object if a new factory function is provided, otherwise the layer's existing factory function

markers.features([features])

Set the contents of a markers layer: run the provided features through the filter function and then through the factory function to create elements for the map. If the layer already has features, they are replaced with the new features. An empty array will clear the layer of all features.

Arguments:

Returns the layer object if a new array of features is provided, otherwise the layer's features

markers.add_feature([feature])

Add a single GeoJSON feature object to the layer.

Arguments:

Returns the layer object

Example:

var markerLayer = mapbox.markers.layer();
var newfeature = {
    geometry: { coordinates: [-77, 37.9] },
    properties: { }
};
// add this single new feature
markerLayer.add_feature(newfeature);
// This call is equivalent to
 markerLayer.features(markerLayer.features().concat([x]));

markers.sort([sortfunction])

Set the sorting function for markers in the DOM. Markers are typically sorted in the DOM in order for them to correctly visually overlap. By default, this is a function that sorts markers by latitude value - geometry.coordinates[1].

Arguments:

Returns the layer object if a new function is specified, otherwise the current function used to sort.

Example:

// The default sorting function is:
layer.sort(function(a, b) {
    return b.geometry.coordinates[1] -
      a.geometry.coordinates[1];
});

markers.filter([filterfunction])

Set the layer's filter function and refilter features. Markers can also be filtered before appearing on the map. This is a purely presentational filter - the underlying features, which are accessed by markers.features(), are unaffected. Setting a new filter can therefore cause points to be displayed which were previously hidden.

Arguments:

Returns the layer object if a new function is specified, otherwise the current function used to filter.

Example:

// The default filter function is:
layer.filter(function() { return true; });

markers.key([idfunction])

Set the key getter for this layer. The key getter is a funcion that takes a GeoJSON feature and returns a unique id for that feature. If this is provided, the layer can optimize repeated calls to markers.features() for animation purposes, since updated markers will not be recreated, only modified.

Arguments:

Returns the layer object if a new function is specified, otherwise the current function used to get keys.

Example:

// The default id function is:
var _seq = 0;
layer.key(function() { return ++_seq; });
// Thus this function always returns a new id for any feature. If you had
// features that do have an id attribute, a function would look like
layer.key(function(f) { return f.properties.id; });

markers.url(url [, callback])

Load features from a remote GeoJSON file into the layer.

Arguments:

Returns the markers layer or the current URL given if no url argument is provided.

markers.id(layerid [, callback])

Load markers from a MapBox layer.

Arguments:

Returns the markers layer.

markers.csv(csvstring)

Convert a string of CSV data into GeoJSON and set layer to show it as features. If it can find features in the CSV string, the markers.features() of the layer are set to them - otherwise it will throw an error about not finding headers.

Arguments:

Returns the markers layer

markers.extent()

Get the extent of all of the features provided.

Returns an array of two { lat: 23, lon: 32 } objects compatible with the map.extent() call. If there are no features, the extent is set to Infinity in all directions, and if there is one feature, the extent is set to its point exactly.

markers.addCallback(event, callback)

Add a callback that is called on certain events by this layer. These are primarily used by mapbox.markers.interaction, but otherwise useful to support more advanced bindings on markers layers that are bound at times when the markers layer object may not be added to a map - like binding to the map's panned event to clear tooltips.

Arguments:

Event should be a String which is one of the following:

Callback is a Function that is called with arguments depending on what event is bound:

Returns the markers layer

markers.removeCallback(event, callback)

Remove a callback bound by markers.addCallback(event, callback).

Arguments:

Returns the markers layer

markers.markers()

Get the layer's internal markers array. Unlike markers.features(), this is not a getter-setter - you can only get the internal markers. Markers are internally objects of { element: DOMNode, location: Location, data: feature } structure, optionally with showTooltip() functions added by mapbox.markers.interaction().

This is direct access to the internal circuitry of markers, and should only be used in very specific circumstances, where the functionality provided by markers.factory(), markers.filter(), etc., is insufficient.

Returns the internal array of marker objects.

Styling markers

By default, markers use pretty styles and a default factory function. markers.factory() allows for custom DOM elements as markers, which should be assigned specific CSS in order to ensure correct placement.

All styles should position elements with position:absolute; and offset them so that the center of the element is in the positioning center - thus the geographic center. So, an element this is 40x40 should be offset by 20 pixels up and to the left.

And in order to support mouse events - like tooltips or hover hints, you'll need to add a rule setting the pointer-events property of the markers:

Example:

.my-custom-marker {
    /* support pointer events */
    pointer-events:all;

    position:absolute;
    width:40px;
    height:40px;

    /* offset to keep a correct center */
    margin-left:-20px;
    margin-top:-20px;
}

mapbox.markers.interaction(markerslayer)

Bind interaction, hovering and/or clicking markers and seeing their details, and customizable through its methods. This supports both mouse & touch input.

Adds tooltips to your markers, for when a user hovers over or taps the features.

This function will create at most one interaction instance per markers layer. Thus you can use it to access interaction instances previously created and to change their settings.

Arguments:

Returns an interaction instance which provides methods for customizing how the layer behaves.

interaction.remove()

Disable interactivity.

Returns the interaction instance.

interaction.add()

Enable interactivity. By default, interactivity is enabled.

Returns the interaction instance.

interaction.hideOnMove([value])

Determine whether tooltips are hidden when the map is moved. The single argument should be true or false or not given in order to retrieve the current value.

Arguments:

Returns the interaction instance.

interaction.showOnHover([value])

Determine whether tooltips are shown when the user hovers over them. The single argument should be true or false or not given in order to retrieve the current value.

Arguments:

Returns the interaction instance.

interaction.exclusive([value])

Determine whether a single popup should be open at a time, or unlimited. The single argument should be true or false or not given in order to retrieve the current value.

Arguments:

Returns the interaction instance.

interaction.formatter([formatterfunction])

Set or get the formatter function, that decides how data goes from being in a feature's properties to the HTML inside of a tooltip. This is a getter setter that takes a Function as its argument.

Arguments:

Returns the interaction instance if a new formatter function is provided, otherwise the current formatter function

Example:

// The default formatter function
interaction.formatter(function(feature) {
    var o = '', props = feature.properties;
    if (props.title) {
        o += '<h1 class="marker-title">' + props.title + '</h1>';
    }
    if (props.description) {
        o += '<div class="marker-description">' + props.description + '</div>';
    }
    if (typeof html_sanitize !== undefined) {
        o = html_sanitize(o,
            function(url) {
                if (/^(https?:\/\/|data:image)/.test(url)) return url;
            },
            function(x) { return x; });
    }
    return o;
});

Styling tooltips

Tooltips, provided in mapbox.markers.interaction, are added to the map as markers themselves, so that they are correctly geographically positioned. You can customize the details of tooltips by changing one of the classes in its DOM structure:

<div class='marker-tooltip'>
    <div>
        <div class='marker-popup'>
            <div class='marker-title'>Your Marker's Title</div>
            <div class='marker-description'>Your Marker's Description</div>
        </div>
    </div>
</div>

Easing

Easing is moving from one point or zoom to another in a fluid motion, instead of just 'popping' from place to place. It's useful for map-based storytelling, since users get a better idea of geographical distance.

mapbox.ease()

Returns an easey object, which has the following methods:

ease.map(map)

Specify the map to be used.

Arguments:

Returns the easey object.

ease.from(coord)

Set the starting coordinate for the easing. You don't usually need to call this, because easings default to the current coordinate.

Arguments:

Returns the easey object.

ease.to(coord)

Set the destination coordinate for the easing.

Arguments:

Since easey deals exclusively in Coordinates, the reference for converting between points, locations, and coordinates in Modest Maps is essential reading.

Returns the easey object.

ease.zoom(level)

Set the zoom level of the to coordinate that easey is easing to.

Arguments:

Returns the easey object.

ease.optimal([V] [,rho] [,callback])

Eases to from in the smoothest way possible, automatically choosing run time based on distance. The easing zooms out and in to optimize for the shortest easing time and the slowest percieved speed. The optional arguments are as defined in Smooth and efficient zooming and panning.

Arguments:

Returns the easey object.

ease.location(location)

Sets the to coordinate to the provided location.

Arguments:

Returns the easey object.

ease.t(value)

Set the map to a specific point in the easing.

Arguments:

Returns the easey object.

ease.future(parts)

Get the future of an easing transition, given a number of parts for it to be divided over. This is a convenience function for calling easey.t() a bunch of times.

Arguments:

Returns an array of MM.Coordinate objects representing each in-between location.

ease.easing(name)

Set the easing curve - this defines how quickly the transition gets to its end and whether it speeds up or slows down near the beginning and end.

Arguments:

Returns the easey object.

ease.path(pathname)

Set the type of path - the type of interpolation between points.

Arguments:

Returns the easey object.

ease.run([time [, callback])

Start an animated ease. Both parameters are optional.

Arguments:

Returns the easey object.

ease.running()

Returns true or false depending on whether easey is currently animating the map.

ease.stop([callback])

Abort the currently running animation.

Arguments:

Returns the easey object.