I have an array that will most likely look like this:
[null, null, null, null, null]
sometimes this array can change to something like:
["helloworld", null, null, null, null]
I know that I could use a for loop to do this, but is there a way to use indexOf to verify that something in the array is not null.
I am looking for something like:
var index = indexof(!null);
source share