Lattice Grid Buy a licence

htmx ยท console.warn

autoInitMap: no {kind} factory registered an...

Printed by htmx, prefixed [lattice], since 1.93.0.

Warnings reference › htmx:map-no-factory:*

Identifier
htmx:map-no-factory:*
Raised by
htmx
Since
1.93.0

What happened

The htmx adapter does not inline any map engine, so a data-lattice-map element needs a factory for its viewer kind (mapview, chart, leaflet or deck): one registered with registerMapFactories(), or the script-tag global the matching module's UMD build publishes. Neither was present for this element's kind, so it was left un-built.

The fix

Load the module for the kind you declared and call registerMapFactories({ mapview: createMapView, chart: createChart, leaflet: bindLeaflet, deck: bindDeck }), or load its UMD build as a <script> tag so the globalThis.LatticeGrid*.createMapView / createChart / bindLeaflet / bindDeck exists.

The smallest fix

import { registerMapFactories } from '@toclocoinc/lattice-grid/modules/htmx';
import { createChart } from '@toclocoinc/lattice-grid/modules/charts';
registerMapFactories({ chart: createChart });

Reference

Covered in full at the API reference.