Skip to main content
Question

Nested arrays are converted into strings


I have a simple nested array generated by a code action step (JS).

const array = [['dog', 'cat'],['zebra', 'giraffe']];

Now, I use a ‘Loop by Zapier’ step to loop through the top level arrays - but every iteration returns a string of the whole array:

dog,cat,zebra,giraffe

 

How do I get the actual subarrays in the loop?

 

Basically I want to be able to use the following:

First iteration:

[‘dog’, ‘cat’]

Second iteration:

[‘zebra’, ‘giraffe’]

 

Is this possible?

Did this topic help you find an answer to your question?
This post has been closed for comments. Please create a new post if you need help or have a question about this topic.