[openstreetmap/openstreetmap-website] Generate maplibre styles from `layers.yml` (PR #6772)

Frank Elsinga notifications at github.com
Sun Feb 8 11:42:57 UTC 2026


@CommanderStorm commented on this pull request.



> +    url_template = insert_api_key(layer, key)
+
+    tiles = if layer["subdomains"]
+              layer["subdomains"].map { |server| url_template.sub("{s}", server) }
+            else
+              [url_template]
+            end
+
+    {
+      :version => 8,
+      :sources => {
+        "raster-tiles-#{layer['layerId']}" => {
+          :type => "raster",
+          :tiles => tiles,
+          :tileSize => 256,
+          :maxZoom => layer["maxZoom"]

`maxzoom` => https://maplibre.org/maplibre-style-spec/sources/#maxzoom_1

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

Message ID: <openstreetmap/openstreetmap-website/pull/6772/review/3769662134 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20260208/ce253fac/attachment-0001.htm>


More information about the rails-dev mailing list