Skip to main content

Module style_json

Module style_json 

Source
Expand description

JSON style-spec parsing and resolution for the style runtime.

This module adds a declarative style-document layer closer to MapLibre’s style/style.ts: JSON source and layer definitions are parsed into a lightweight spec and then resolved through a host-provided runtime source registry into an executable StyleDocument.

Structs§

StyleSourceRegistry
Runtime source registry used while resolving JSON specs.
StyleSpecDocument
Declarative JSON style document.
StyleSpecLayer
Declarative layer entry.
StyleSpecProjection
Top-level projection entry in a JSON style spec.
StyleSpecSource
Declarative source entry.
StyleSpecTerrain
Top-level terrain entry in a JSON style spec.

Enums§

StyleSpecError
Errors produced while parsing or resolving a JSON style specification.
StyleSpecLayerType
Layer kinds accepted by the JSON style spec.
StyleSpecProjectionType
Projection kinds accepted by the current JSON style spec.
StyleSpecSourceType
Source kinds accepted by the JSON style spec.

Functions§

parse_style_json
Parse a JSON style string.