Item getter
Last updated
Last updated
[data/array/Item getter]
Retrieves item from the specified index.
If the item is not found, the inputs are sent via not found
.
Example A:
[1,2]@0 received via array
1@0 recieved via index
2@0 sent via item
Example B:
[1,2]@0 received via array
9@0 recieved via index
{"array":[1,2], "index":9}@0 sent via not found
More: https://github.com/Cranq-io/cranq-tutorials/blob/main/reference/3_querying_data/3_1_getters/README.md#getting-array-element-by-index
Keywords: select, retrieve, access
array: any[]
Recieves array to retrieve item from. Example: [1,2]
index: number
Recieves index which identifies item to be retrieved in the array. Example: 1
item: any[][number]
Sends item at the specified index. Example: 2
not found: {"array": any[], "index": number}