Skip to content

Releases: immerjs/immer

v7.0.9

09 Sep 14:29
9257084
Compare
Choose a tag to compare

7.0.9 (2020-09-09)

Bug Fixes

  • clear map creates invalid patches, fixes #663 (bacc1e0)

v7.0.8

25 Aug 17:37
bf90358
Compare
Choose a tag to compare

7.0.8 (2020-08-25)

Bug Fixes

  • Use a named type for Draft object for smaller type declaration files (a1a0da0)
  • use Array.prototype.slice() for copying arrays. Fixes #650 (bf90358)
  • use Array.prototype.slice() for copying arrays. Fixes #650 (bb40c36)

v7.0.7

24 Jul 19:42
Compare
Choose a tag to compare

7.0.7 (2020-07-24)

Bug Fixes

  • made NOTHING and IMMERABLE shared symbols. Fixes #632 (b1c6a8e)
  • make sure changing an undefined value to undefined is not picked up as change. Fixes #646 (5521527)
  • out of range assignments were broken in ES5 mode. Fixes #638 (0fe9132)
  • Set finalization can get stuck in a loop, fixes #628 (b12e5c9)
  • Trigger setters with the correct context, fixes #604 (2697430)

v7.0.6

24 Jul 15:31
b355838
Compare
Choose a tag to compare

7.0.6 (2020-07-24)

Bug Fixes

  • flow: added types for produceWithPatches (b355838)

v7.0.5

24 Jun 08:38
Compare
Choose a tag to compare

7.0.5 (2020-06-24)

Bug Fixes

  • Fixed regression in Object.frozen for IE11. Fixes #600 (6371d05)

v7.0.4

22 Jun 13:05
9022672
Compare
Choose a tag to compare

7.0.4 (2020-06-22)

Bug Fixes

  • Flow: Add tests for Map and Set and fix base type (9022672)
  • new map keys were not added if value is undefined (4a1bd65)

v7.0.3

19 Jun 17:20
Compare
Choose a tag to compare

7.0.3 (2020-06-19)

Bug Fixes

  • getOwnPropertyDescriptors is not available in Internet Explorer and Hermes. Fixes #626 (c7a47e2)

v7.0.2

19 Jun 17:00
Compare
Choose a tag to compare

7.0.2 (2020-06-19)

Bug Fixes

  • Fixed #620: Symbolic properties were not drafted or finalized correctly (91915cf)

v7.0.1

12 Jun 19:35
7d6b57b
Compare
Choose a tag to compare

7.0.1 (2020-06-12)

Bug Fixes

  • Add missing type current for pre-TS 3.7 types (7d6b57b)

v7.0.0

10 Jun 20:32
467ea5d
Compare
Choose a tag to compare

7.0.0 (2020-06-10)

  • Introduced current, which takes a snapshot of the current state of a draft and finalizes it (but without freezing). Current is a great utility to print the current state during debugging (no Proxies in the way), and the output of current can also be safely leaked outside the producer. Implements #441, #591

  • [BREAKING CHANGE] getters and setters are now handled consistently: own getters and setters will always by copied into fields (like Object.assign does), inherited getters and setters will be left as-is. This should allow using Immer directly on objects that trap their fields, like done in Vue or MobX. Fixes #584, #439, #593, #558

  • [BREAKING CHANGE] produce no longer accepts non-draftable objects as first argument

  • [BREAKING CHANGE] original can only be called on drafts and will throw otherwise (fixes #605)

  • [BREAKING CHANGE] non-enumerable and symbolic fields will never be frozen

  • [BREAKING CHANGE] the patches for arrays are now computed differently to fix some scenarios in which they were incorrect. In some cases they will be more optimal now, in other cases less. Especially splicing / unshifting items into an existing array might result in a lot of patches. Fixes #468

  • Improved documentation in several areas, there is now a page for typical update patterns and a separate page on how to work with classes. And additional performance tips have been included. Fixes #457, #115, #462

  • Fixed #462: All branches of the produced state should be frozen

  • Fixed #588: Inconsistent behavior with nested produce

  • Fixed #577: Immer might not work with polyfilled symbols

  • Fixed #514, #609: Explicitly calling useProxies(false) shouldn’t check for the presence of Proxy.