When chaining multiple assign/merge calls that need to change the object root, I was expecting them all to have an effect. Instead only the last assign/merge is applied.
const obj = { a: 1 }
const newObj = immutable(obj).assign(null, { b: 2 }).assign(null, { c: 3 }).value()
Expected output
Actual output
If this is expected behavior it might be worth pointing it out in the documentation.
When chaining multiple
assign/mergecalls that need to change the object root, I was expecting them all to have an effect. Instead only the lastassign/mergeis applied.Expected output
Actual output
If this is expected behavior it might be worth pointing it out in the documentation.