According to the docs here: https://facebook.github.io/immutable-js/docs/#/Map/getIn
I should be able to get the deeply nested value by providing an array for the keyPath
argument. This is what I've done, however I'm getting undefined
as the return value.
var obj = Immutable.Map({categories: {1: 'a', 2: 'b'}});
var output = obj.getIn(['categories', 1]);
alert(output);
What am I doing wrong?