[openstreetmap/openstreetmap-website] Minimap migration from Leaflet to MapLibre (PR #6683)

Pablo Brasero notifications at github.com
Mon Jan 19 11:42:50 UTC 2026


@pablobm commented on this pull request.



> @@ -0,0 +1,36 @@
+const createRasterStyle = function (maxzoom, tileUrl) {

(Ooops, I left this comment here last week, but I didn't properly post the review so it didn't publish).

Thank you, one day I might understand this stuff 😅 I'll try to explain based on my Rails experience (in absence of relevant OSM experience):

Data from yml files typically will be loaded in `.js.erb` files as it needs to be read from filesystem into a template. I searched for `layers.yml`, and found it at [app/assets/javascripts/osm.js.erb](https://github.com/openstreetmap/openstreetmap-website/blob/deb5277ca5fef3321bd77652aa9bb03331bacea3/app/assets/javascripts/osm.js.erb#L34), loaded as `OSM.LAYER_DEFINITIONS`, which you can reference from this file. The specific definitions to load are selected by [lib/map_layers.rb](https://github.com/openstreetmap/openstreetmap-website/blob/deb5277ca5fef3321bd77652aa9bb03331bacea3/lib/map_layers.rb).

Still, the yml is missing the tile URLs, so either they should be added to the yml, or we add them manually like you do there. I would normally go for the first option, but I don't know the history here so there might be other things I'm missing.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6683#discussion_r2686022790
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/6683/review/3655326213 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20260119/8376f203/attachment.htm>


More information about the rails-dev mailing list