Skip to main content

layerAction

Performs an action on another layer.

Field Configurations

KeyTypeDescriptionDefault Value
"params" (required)Objectundefinednull

Parameters

KeyTypeDescriptionDefault Value
"actions" (required)ArrayThe list of action, that will be performed on the other layer.null
"async"BooleanSpecifies whether the action should perform asynchronously.null
"layerName" (required)StringThe name of the other layer. (not the dataKey)null
"location"LocationLocation inside the app.null

Inherited

From Base Action

Base Action

Field Configurations

KeyTypeDescriptionDefault Value
"dynamicParams"ObjectDynamic params to retrieve data from a specific context e.g. a userSetting.null
"leadingDelimiter"StringThe leading mustache delimiter to use.null
"params"Object,ArrayObject containing the properties of the action.null
"trailingDelimiter"StringThe trailing mustache delimiter to use.null
"type"StringType name of the action.null

Examples

Example 1: Set a new title for the navbar

Goal: Create a layerAction action setting a new value for the title layer in the navbar.

The location and layerName parameter specify the layer that an action is to be performed on.

{
"type": "layerAction",
"params": {
"location": "navbar",
"layerName": "title",
"actions": [
{
"type": "setLayerValue",
"params": {
"value": "The new navbar title"
}
}
]
}
}

The actions parameter specifies the actions that are to be performed on the layer.

Result:

A layerAction action has been created.