Skip to content

We will need to rebuild leaflet w/ the latest version of leaflet-providers. For now you can do #637

Closed
@mikeshaw-omnicell

Description

Hello, I'm having issues accessing Thunderforest tiles through Leaflet. I found this post on the subject from two years ago:

#410

We will need to rebuild leaflet w/ the latest version of leaflet-providers. For now you can do

leaflet() %>%
  addTiles(
    urlTemplate = "https://{s}.tile.thunderforest.com/{variant}/{z}/{x}/{y}.png?apikey={apikey}",
    attribution = "&copy; <a href='http://www.thunderforest.com/'>Thunderforest</a>,  &copy; <a href='http://www.openstreetmap.org/copyright'>OpenStreetMap</a>",
    options = tileOptions(variant='transport-dark', apikey = 'YOUR-KEY')
  )

You should pass in your key and use which ever variant you want.

Originally posted by @bhaskarvk in #410 (comment)

The method described does not seem to be working. Has leaflet been rebuilt (as hinted) with updated syntax?

Thanks!

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions