Say I’ve got this
imageList = [100,200,300,400,500];
Which gives me
[0]100 [1]200
etc.
Is there any way in JavaScript to return the index with the value?
I.e. I want the index for 200, I get returned 1.
Say I’ve got this
imageList = [100,200,300,400,500];
Which gives me
[0]100 [1]200
etc.
Is there any way in JavaScript to return the index with the value?
I.e. I want the index for 200, I get returned 1.