Michael Lin
Michael Lin
- Based on the benchmark comparison from `test/performance/benchmark-reducer1.mjs`: Before: ``` remove: vanilla (freeze: false) 1.04x faster than remove: vanilla (freeze: true) 2349.65x faster than remove: immer10 (freeze: true) 3000.06x faster...
This PR focuses solely on performance optimization for Array operations such as `splice`, `shift`, `reverse`, and `unshift`, while ensuring the correctness of immutable updates. However, the optimization makes the draft...
hi @rmdort, thank you very much. I will consider refactoring this PR and merging it as soon as possible.
Since this breaking change will cause destructive differences in Array data patches and to ensure stability, we will add a new option enableOptimizedArray (disabled by default) for this optimization. Once...
hi @qcho, you should be explicit with your type declarations. Otherwise, regardless of whether you use Mutative, you will get a type error. Like this, ```ts const base = {...
hi @atsjo, I may start implementing this API soon.
These drafts are not finalized, which means they might require shallow copying under the immutable mechanism, and the draft instances will not be garbage collected. I don’t really recommend doing...
> ok, thanks for the info! > > I normally use it like a normal producer, but also have a forms based ui bound to a json structure, where this...
> Just wanted to add another use case that I believe would be able to take advantage of this wonderful proposal: > > * interleaving other non-standard operations inside `create`'s...
1. Regarding the return type of `current(Draft)`: Indeed, changing the return type to `T` instead of `Draft` is more reasonable. The purpose of the `current()` function is to get the...