Closed jameshopkins closed 8 years ago
I'm not sure you can use withMutations
to change things nested in the map. The mutable copy is of the map only, not everything stored in it. The documentation also points out that:
Note: Not all methods can be used on a mutable collection or within withMutations! Only set and merge may be used mutatively.
The point of withMutations
is to speed up a series of set
s, not all the calls of all the mutative APIs on everything stored within. I'm not even sure how that would work :)
yields:
when I would expect: