Function QuadTileLayer

Source
pub fn QuadTileLayer(props: QuadTileLayerProps) -> impl IntoView
Expand description

A quad tile layer component that uses quadkey-based URLs. Instead of the standard {z}/{x}/{y} pattern, this component expects URLs with a {q} placeholder for the quadkey.

§Example

use leptos::prelude::*;
use leptos_leaflet::prelude::*;

#[component]
pub fn MapWithQuadTiles() -> impl IntoView {
    view! {
        <MapContainer style="height: 400px" center=Position::new(51.505, -0.09) zoom=13.0>
            <QuadTileLayer
                url="https://example.com/tiles/{q}.png"
                attribution="&copy; Example Tile Provider"/>
        </MapContainer>
    }
}

The quadkey format is used by Microsoft Bing Maps and some other tile providers. Each tile is identified by a quadkey string that represents the tile’s location in the quad tree, rather than separate x/y/z coordinates.

§Required Props

§Optional Props