MapValues
Map the given values to the translated values. If given values: a,b,c, and translated: 1,2,3, then the input will return 1.
javascript · Common Scripts
Details
| ID | MapValues |
|---|---|
| Language | javascript |
| From Version | 5.0.0 |
| Tags | Utility |
README
Maps the given values to the translated values.
If given values: “a,b,c” and translated: 1,2,3 then input “a” will return a 1.
Script Data
| Name | Description |
|---|---|
| Script Type | javascript |
| Tags | Utility |
Inputs
| Argument Name | Description |
|---|---|
| values | The values that should be translated. |
| translated | The translated values to be used to replace the values. |
| input | The value to compare and replace. |
Outputs
There are no outputs for this script.
commonfields: id: MapValues version: -1 name: MapValues script: '' type: javascript tags: - Utility comment: 'Map the given values to the translated values. If given values: a,b,c, and translated: 1,2,3, then the input will return 1.' system: true args: - name: values required: true default: true description: The values we should translate. - name: translated required: true description: The translated values we will use to replace the values. - name: input required: true description: The value to compare and replace. scripttarget: 0 fromversion: 5.0.0 tests: - No tests