tile_json | R Documentation |
Intended for use as the data
parameter of mvt_layer()
. Creates a tile json url
from a tileset_id and tile_service. Tile service defaults to
getOption("rdeck.tile_service") %||% "mapbox"
.
The created url will be fetched and parsed with jsonlite::fromJSON()
.
tile_json(tileset_id, tile_service = NULL)
tileset_id |
<
|
tile_service |
< |
Authentication via mapbox_access_token()
occurs when tile_service = "mapbox"
,
or tileset_id
uses the mapbox scheme (i.e. mapbox://).
## Not run:
tile_json("mapbox.mapbox-streets-v8", "mapbox")
tile_json("mapbox.mapbox-streets-v8.json", "mapbox")
tile_json("mapbox://mapbox.mapbox-streets-v8")
tile_json("mapbox://mapbox.mapbox-streets-v8.json")
tile_json("https://mytileserver/tileset.json")
tile_json("tileset.json", "https://mytileserver")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.