@honua/sdk-js/runtime — MapLibre GL JS-first runtime for Honua HonuaMapDocument. Consumes a server-produced HonuaMapDocument and binds it to a caller-provided MaplibreMap instance.
@honua/sdk-js/runtime
HonuaMapDocument
MaplibreMap
import { HonuaClient } from "@honua/sdk-js";import { loadMapDocument } from "@honua/sdk-js/runtime";import * as maplibregl from "maplibre-gl";const map = new maplibregl.Map({ container: "map" });const runtime = await loadMapDocument(pkg, map, { client: new HonuaClient({ baseUrl: "https://honua.example.com" }), popupFactory: () => new maplibregl.Popup(),});runtime.setLayerVisibility("parcels-fill", false);await runtime.updateMapDocument(nextPkg); Copy
import { HonuaClient } from "@honua/sdk-js";import { loadMapDocument } from "@honua/sdk-js/runtime";import * as maplibregl from "maplibre-gl";const map = new maplibregl.Map({ container: "map" });const runtime = await loadMapDocument(pkg, map, { client: new HonuaClient({ baseUrl: "https://honua.example.com" }), popupFactory: () => new maplibregl.Popup(),});runtime.setLayerVisibility("parcels-fill", false);await runtime.updateMapDocument(nextPkg);
@honua/sdk-js/runtime— MapLibre GL JS-first runtime for HonuaHonuaMapDocument. Consumes a server-producedHonuaMapDocumentand binds it to a caller-providedMaplibreMapinstance.Example