I have the following:
var tempList = []
// or
var tempList = new Array()
when I test what it is, it returns an object. How can I initialize it as an array and why is this weird error occurring?
console.log(typeof tempList); // object
I have the following:
var tempList = []
// or
var tempList = new Array()
when I test what it is, it returns an object. How can I initialize it as an array and why is this weird error occurring?
console.log(typeof tempList); // object