I can't understand why the result of code execution gonna be -1
(in strict mode only):
'use strict'
[0,1].indexOf(0)
Is it bug or there is some other reason?
Note: in normal mode it works as expected: index of 0 is 0
I try to analyze Polyfills code on mdn and have just one idea why it can happen: in strict mode in some cases this
is not refer to window, but to 'undefined'.