Hi there,
So I have this very, very simple code in a function somewhere:
var index = array.indexOf("value");
if (index > -1){
console.log("hello");
} else {
console.log("goodbye");
}
In Chrome, it works perfectly. However, in ionic view or once I compile it (I only tested iOS), on simulator and on an actual device, the code doesn’t log and do anything at all. If I set index
manually, it works as expected.
What am I missing here?
Thanks!