@mapcreator/mapcreator-gl
v5.2.3
Published
Mapcreator interactive maps library
Downloads
525
Readme
Mapcreator interactive maps library. Uses Maplibre GL JS internally and adds Mapcreator-specific features to it.
Installation
npm i --save @mapcreator/mapcreator-glUsage
// Import library scripts
import { init } from '@mapcreator/mapcreator-gl';
// Import library styles
import '@mapcreator/mapcreator-gl/dist/lib/style.css';
// Initialize the map
const map = await init({
container: '<map container element or its id>',
jobId: '<interactive map id>',
accessToken: '<mapcreator access token>',
});
// map is now an instance of MapLibre GL JS:
//
// map.setZoom(10);
// map.getZoom();