Closed juliendorra closed 7 years ago
Thanks, I can’t believe I missed this. Since order is important to us, arrays seem the right solution here (apart from partial browser support and having to insert entries in the order you want them, you can’t “send” a Map
unless you define an unequivocal serialization format for them).
Order of objects in the list in the programmer is not guaranteed, as the list is send as a Javascript object, not an Array or a (newer) Map object. An example is integers in Chrome: they are considered index, and treated before non-index
Example, try that on Chrome:
The behavior should be different on Firefox.
Some context: https://stackoverflow.com/a/23202095
We should send or transform the objects list as an array or map object to get a reliable order.