The fullscreen control adds a link to the map that assigns a fullscreen class to the map, which makes it fill the page.
You’ll see that this control adds a fullscreen link to the map, and that it’s
a bit ugly right now. Until Wax’s theming improves, keep in mind that its
styling, which is contained in theme/controls.css
, is completely optional
and you can replace it with your own.
wax.tilejson( 'https://api.tiles.mapbox.com/v3/mapbox.natural-earth-2.jsonp', function(tilejson) { var m = new MM.Map('map-div', new wax.mm.connector(tilejson)); wax.mm.fullscreen(m, tilejson).appendTo(m.parent); m.setCenterZoom({ lat: 39, lon: -98 }), 2); });