I'm getting different results for this fiddle on Google Chrome (14.0.835.186) and Firefox (6.0.2).
Can anyone explain the discrepancy? What is the behaviour determined by the specifications?
EDIT: On Firefox I see [0]
, [0, 1]
, etc. On Chrome I see [0, 1, 2, 3, 4]
, [0, 1, 2, 3, 4]
, [0, 1, 2, 3, 4]
, etc.
I'm using Mac OS 10.6.8.
Firefox is more technically correct in this case as it outputs the state of the object at each point in the loop whereas Chrome is apparently waiting until the end of the loop to output each console.log, but I'm not aware of a standards specification that covers the console host object.
See this jsFiddle: http://jsfiddle.net/jfriend00/LRGP2/ to show that this is only console.log that has this odd behavior.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With