Merge pull request #14062 from Firefishy/update-tile.openstreetmap.org-url

Use preferred tile.openstreetmap.org URL
This commit is contained in:
MoonE
2022-08-28 02:22:00 +02:00
committed by GitHub
2 changed files with 3 additions and 3 deletions

View File

@@ -23,7 +23,7 @@ new Map({
layers: [
new TileLayer({
source: new XYZ({
url: 'https://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png'
url: 'https://tile.openstreetmap.org/{z}/{x}/{y}.png'
})
})
],

View File

@@ -37,7 +37,7 @@ export const ATTRIBUTION =
* ```
* @property {number} [transition=250] Duration of the opacity transition for rendering.
* To disable the opacity transition, pass `transition: 0`.
* @property {string} [url='https://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png'] URL template.
* @property {string} [url='https://tile.openstreetmap.org/{z}/{x}/{y}.png'] URL template.
* Must include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
* @property {boolean} [wrapX=true] Whether to wrap the world horizontally.
* @property {number|import("../array.js").NearestDirectionFunction} [zDirection=0]
@@ -70,7 +70,7 @@ class OSM extends XYZ {
const url =
options.url !== undefined
? options.url
: 'https://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png';
: 'https://tile.openstreetmap.org/{z}/{x}/{y}.png';
super({
attributions: attributions,