@honua/sdk-js
    Preparing search index...

    Function useMapSelectionBinding

    • Experimental

      Two-way binding between a mounted MapLibre layer set and the enclosing HonuaSelectionProvider:

      • layer clicks toggle the clicked feature in the shared store;
      • every store change (from the map or from non-map components) is mirrored onto MapLibre feature-state under stateKey, so paint expressions like ["case", ["boolean", ["feature-state", "selected"], false], …] respond.

      Requires a map with on/off and setFeatureState (any MapLibre map). No-ops while the map is null or there is no enclosing HonuaSelectionProvider. StrictMode-safe: listeners and mirrored feature-state are fully removed on cleanup.

      Parameters

      Returns void