Skip to main content

saveImageLocally

Saves a captured image to the local storage of the app.

note

This action is intended to work with a picker layer that has its allowMultipleSelection property set to false only. Using this action with a picker layer that has the allowMultipleSelection property set to true is unsupported!

Field Configurations

KeyTypeDescriptionDefault Value
"params" (required)Objectundefinednull

Parameters

KeyTypeDescriptionDefault Value
"async"BooleanSpecifies whether the action should perform asynchronously.null
"form" (required)StringName of the form to use.null
"formDataKey" (required)StringForm data key in which the image was saved.null
"imageName"StringName under which the image should be saved.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: Save image locally

Goal: Saving an image after you picked it with the picker layer.

To achieve this the following code can be used:

{
"type": "saveImageLocally",
"params": {
"form": "imageUpload",
"formDataKey": "imagePicker",
"imageName": "image"
}
}

The example will save the image into the namedForm imageUpload:imagePicker with the name image.

Result:

A saveImageLocally action has been created.