跳到正文
Simon Willison·· 20 天前

datasette-leaflet 0.3

datasette-leaflet 0.3

中文摘要

发布:datasette-leaflet 0.3。OpenStreetMap 有一个非常合理的策略,即对其托管的瓦片服务器的请求应发送一个来源(referrer)头。Datasette 表格页面之前使用了 Referrer-Policy: no-referrer HTTP 头,导致从 OpenStreetMap 加载瓦片的插件违反了该策略。datasette-leaflet 是一个加载了内置 Leaflet 的插件,其他 Datasette 插件可以依赖它。现在,它将来源策略设置为 strict-origin-when-cross-origin,传递主机名但不传递页面的完整路径。标签:leaflet,datasette,openstreetmap

英文原文

Release: datasette-leaflet 0.3 OpenStreetMap have a very reasonable policy that hits to their hosted tile server should send a referrer header . Datasette table pages used the Referrer-Policy: no-referrer HTTP header, causing plugins that loaded tiles from OpenStreetMap to violate that policy. datasette-leaflet is the plugin that loads a bundled Leaflet so other Datasette plugins can depend on it. It now sets the referrer policy on the tile requests themselves to strict-origin-when-cross-origin , passing the host but not the full path to the page. Tags: leaflet , datasette , openstreetmap

应来源方要求,这里只提供摘要与原文入口。完整内容请阅读原文。

来源:Simon Willison · simonwillison.net