jbkunst / highcharter

R wrapper for highcharts
http://jkunst.com/highcharter/
Other
720 stars 148 forks source link

Feature Request: Add TiledWebMap module functionality / Upgrade Highcharter Version #801

Open anthonyokc opened 1 year ago

anthonyokc commented 1 year ago

Hi Joshua,

I am loving the package so far and its producing wonderful maps for me! Here's an example:

image

In this case though, I thought it beneficial if I could use the new TiledWebMap module from highcharter, so users could see more specific geographic detail for the areas (street numbers, buildings, and the like).

So, I forked the repo and attempted to upgrade highcharter as you had done here. Then, I ran the following code.

# remotes::install_github("AnthonyOKC/highcharter@upgrade-to-highcharts-v11.1.0")
library(highcharter) # This is the version from the forked repo above.

highchart(type = "map") |>
    hc_add_dependency("modules/tiledwebmap.js") |> 
    hc_add_series(
        type = "tiledwebmap",
        provider = list(
            type = "OpenStreetMap",
            theme = "Standard",
            subdomain = "a"
        )
    )

However, I still received a blank page. I can confirm that tiledwebmap.js was in the modules folder and that highcharter.js was using the new version.

This was my best attempt with the little knowledge I have about how you got this great package working. I would greatly appreciate if you had any suggestions as to what I might be missing, or if you had any plans to upgrade to a working v11.1.0 for at least the dev version of the package. It has a lot of other neat features and changes to old charts so it might be worth it. Also, I really don't want to have to use leaflet... 🙏

Thank you for your time!