Skip to main content

@mapgear/geoapps > Permalinks

Provides access to the Permalinks functionality. Can be accessed through the Map.Permalinks-property.

Signature:
export declare class Permalinks 

Remarks

The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the Permalinks class.

Example

An example of the usage:

// Connect as anonymous user to a geoapps environment
geoapps.Initialize("<specified tenant>");

// Add the map to a div with element id `map`
var map = geoapps.AddMap("map", "<mapId>");

// Wait till the map loaded, before starting permalinks
map.onLoaded.add(() => {
// Apply permalink
map.Permalinks.Apply(<key>);

// Generate permalink
map.Permalinks.Generate(<type>);

// Post permalink to server
map.Permalinks.PostPermalink(<type>);
});

Methods

MethodModifiersDescription
Apply(key)Apply permalink to mapviewer
Generate(type)Generate a permalink for the user
PostPermalink(type)Create a permalink for the user