Skip to content
Myr

Merge pull request #193 from TomFaulkner/patch-2

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Update readme.md

authored by Michel Weststrate · committed by GitHub · parents 1401c08, 47f67b0 · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:readme.md+1 added-1 removed
583 unmodified lines
584![performance.png](images/performance.png)585586Most important observation:587588* Immer with proxies is roughly speaking twice to three times slower as a hand written reducer (the above test case is worst case, se `yarn test:perf` for more tests). This is in practice negligible.588* Immer with proxies is roughly speaking twice to three times slower as a hand written reducer (the above test case is worst case, see `yarn test:perf` for more tests). This is in practice negligible.589* Immer is roughly as fast as ImmutableJS. However, the _immutableJS + toJS_ makes clear the cost that often needs to be paid later; converting the immutableJS objects back to plain objects, to be able to pass them to components, over the network etc... (And there is also the upfront cost of converting data received from e.g. the server to immutable JS)590* Generating patches doesn't significantly slow immer down591* The ES5 fallback implementation is roughly twice as slow as the proxy implementation, in some cases worse.592
39 unmodified lines