• JMap.MapContext.setContextTitle

    Updates a map context title, without changing the map data.

    The map-context title is persisted server-side.

    Parameters

    • contextId: JId

      the JMap map context id

    • title: string

      the new title

    Returns Promise<void>

    Throws

    if context not found, or empty title, or server request error

    Example

    // update the map-context id=3 title
    JMap.MapContext
    .setContextTitle(3, "My new title")
    .then(() => console.info(`Map context id=3 "title" updated`))
    .catch(error => console.error(error))