Skip to content

getIn and hasIn do not work on IE10/11 #1645

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
cvoege opened this issue Nov 7, 2018 · 1 comment
Closed

getIn and hasIn do not work on IE10/11 #1645

cvoege opened this issue Nov 7, 2018 · 1 comment
Labels
Milestone

Comments

@cvoege
Copy link

cvoege commented Nov 7, 2018

What happened

getIn and hasIn do not work with object properties on IE10/IE11. They always return null even if the property exists.

How to reproduce

Open IE 11 or IE 10 and try this code snippet:

var map = Immutable.Map({
  mapKey: Immutable.List([
    {
      objectKey: 'objectValue'
    }
  ])
})

console.log(map.getIn(['mapKey', 0, 'objectKey'])) // Should print 'objectValue', instead prints null

Expected Behavior

getIn should return the values for the properties in a nested object. It does so on Chrome/Firefox/Safari, but on IE10 and 11 It instead always returns null.

getIn and hasIn both work correctly with Immutable.js collections in IE10 and 11, for example, this works in all browsers:

console.log(map.getIn(['mapKey', 0]).objectKey) // Prints objectValue!

It just doesn't work with object properties. I've tested this on 4.0.0-rc.12 and 4.0.0-rc.10, and the bug exists on both.

@jdeniau
Copy link
Member

jdeniau commented Jul 13, 2021

I tried it and this appear to be fixed in 4.0.0-rc.14.

Probably fixed by immutable-js-oss#194

@jdeniau jdeniau closed this as completed Jul 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants