Login to follow
MapBox

MapBox (ODC)

Stable version 0.1.0 (Compatible with ODC)
Uploaded on 10 November 2022 by Noesis
MapBox

MapBox (ODC)

Documentation
0.1.0
  • On the screen you want to add a map in the OnInitialize event add the action "Load_Mapbox" this will add the necessary MapBox JS to the html header
  • OnReady the action Init_Map should be called, this action receives a couple of parameters
    • MapInit (has the container id where the map will be rendered as well as the initial data of where the map will be positioned)
    • AccessToken (you can get from https://www.mapbox.com/ after creating an account)
    • Define a source (more details below)
    • Define a layer (more details below)
    • Define a handler that will be called when the map is loaded with the action "Create_On_Handler"

Defining a source

A source is added using the action "Add_Source" that receives a source and a source will need a dataSet

This DataSet can be a list of features, for example:

Defining a layer: