GeoLeaf Core API - v3.0.0
    Preparing search index...

    Common options for GeoJSON and vector layers.

    The index signature allows adapters to accept engine-specific style overrides from advanced callers without losing type safety on the known properties.

    interface GeoLeafLayerOptions {
        visible?: boolean;
        opacity?: number;
        zIndex?: number;
        interactive?: boolean;
        attribution?: string;
        cluster?: boolean;
        clusterRadius?: number;
        clusterMaxZoom?: number;
        minZoom?: number;
        maxZoom?: number;
        [key: string]: unknown;
    }

    Indexable

    • [key: string]: unknown

      Forward-compatibility escape hatch for engine-specific options.

    Index

    Properties

    visible?: boolean

    Whether the layer is rendered on the map.

    true
    
    opacity?: number

    Layer opacity. Range: 0 (transparent) … 1 (opaque).

    1
    
    zIndex?: number

    Stacking order relative to other layers. Higher = on top.

    interactive?: boolean

    Whether the layer responds to pointer events.

    true
    
    attribution?: string

    HTML string shown in the attribution control.

    cluster?: boolean

    Enable MapLibre native Supercluster on this GeoJSON source (Point layers only).

    clusterRadius?: number

    Cluster radius in pixels.

    50
    
    clusterMaxZoom?: number

    Max zoom at which clusters are generated.

    14
    
    minZoom?: number

    Lowest zoom at which the layer renders — a MapLibre ZOOM LEVEL (0-24), not a scale denominator. Profiles express the constraint as scaleConfig.minScale (1:X); the loader converts it with scaleToZoom(scale, lat) before it reaches the adapter.

    Distinct from clusterMaxZoom, which is a Supercluster threshold on the SOURCE, not a rendering bound on the layer.

    maxZoom?: number

    Highest zoom at which the layer renders — a zoom level, see minZoom.