After upgrading one of our apps to 2.7, it failed to load in IE9. I reproduced the issue by installing a new sandbox app with v2.7. The error is thrown in supportsHashChange with global being undefined.
function supportsHashChange(documentMode, global) {
return 'onhashchange' in global && (documentMode === undefined || documentMode > 7);
}
Reverting to 2.6 resolves the issue.
@darylalexjohnson can you share the repository you used to reproduce the issue, here? It will be helpful for confirming and debugging the issue.
I can confirm this happens with a vanilla 2.7.0 ember init on IE9. I can throw up a repo but it would just be a vanilla ember init repo.
SCRIPT5007: Invalid operand to 'in': Object expected
vendor.js, line 37313 character 5
I can also confirm this. Try to see the live demo on IE9 of a simple ember app running 2.7: https://github.com/zoltan-nz/library-app.
Like @darylalexjohnson was pointing out, the global param is undefined here.
Hmm. Our test suite runs against IE9 and seems to be passing. Does someone have a minute to try and submit a failing test case?
I wonder if this is coming from Ember itself or something that is included by default in a new ember-cli app. I'll try to get my IE9 VM working again to test, but it may take a few days (doing a bit of vacation...)
@rwjblue If you have IE11 running, you can also simulate IE9, which is giving you more useful console output also. Will see if I can create a failing test if I have some time tomorrow (also a bit of vacation ;) )
I can confirm that this happens when visiting https://ember-twiddle.com/ , which is currently on ember 2.7.0. Tested with IE9 on windows 7 through Browserstack.
This is due to a rename from environment.global to environment.window in this commit
https://github.com/emberjs/ember.js/commit/93f1a8fbd92d416451f56ec0bc0da1c259a20349
However this still tries to use environment.global, which is no longer defined
https://github.com/emberjs/ember.js/blob/v2.7.0/packages/ember-routing/lib/location/auto_location.js#L73
Can someone take a look at this, seems crucial to me.
Thx @rwjblue
Most helpful comment
Can someone take a look at this, seems crucial to me.