user6867266 user6867266 - 1 year ago 56
Javascript Question

why is d3 each() function only iterating through first item in list?

For some reason, when I implement the d3 each() function it only acts upon the first item in an array. For example, in the following function, only the user ID of the first user in the array is alerted:,js

What am I missing here?

Answer Source

U can do forEach like this: