5 ms·
Immerjs is a very handy library for doing this kind of thing. It is a natural fit for react but can be used for any kind of copying like this.
by cageface 8y ago
Immerjs is a very handy library for doing this kind of thing. It is a natural fit for react but can be used for any kind of copying like this.
- 0xFACEFEED 8y ago+1 for immer. I love it. If anyone here ends up using it, make sure you learn how it works first. There are performance implications. It may not matter but it's important to know what they are. Also it's generally best practice to learn how magical utilities like immer do what they do before using them!