I was using for...in loops to log values, and I noticed that the variable in a for...in loop (i, in this case) is a string.
for (var i in ['a', 'b', 'c']) {
console.log(i, typeof i)
}
I searched the ECMAScript specifications, in the section titled "The for-in, for-of, and for-await-of Statements", for any information on this, but could not find anything on this.
My question is, is there anything in the spec about this, and if not, why is it a string?