Skip to main content

Attach the map editor

Mount the Kaleidr editor in your page and let users design a map.

<div id="editor" style="height:640px"></div>
<script src="https://cdn.kaleidr.com/embed/v1/kaleidr.js"></script>
<script>
const handle = Kaleidr.mount('#editor', {
product: 'editor',
publishableKey: 'kld_pk_live_…', // design scope
});
// later: handle.destroy();
</script>

The editor creates its own MapLibre map inside #editor. Its map-design helpers (analyze a dataset, build a layer) call the platform design surface with your key, billing the design scope. Pass styleId (a full style URL) to start from a basemap. See Editor attach.