Skip to content

Releases: nx-js/observer-util

v4.2.2

13 Feb 08:22
Compare
Choose a tag to compare

Fixes

  • Fixed a crash on sites with CSP set up (#39)

v4.2.1

22 Jan 11:55
Compare
Choose a tag to compare

Fixes

  • Fixed object values in ES6 collections (Map, Set, WeakMap, WeakSet) not being wrapped by observables when requested from inside reactions. (This caused reactions not running in some cases when an ES6 collection was part of an observable store.)

v4.2.0

09 Jun 19:31
Compare
Choose a tag to compare

Features

  • Symbol keyed and function valued properties are also observables. (Well known symbol keyed props are still not observables and they will likely never be).
  • Mutations in reactions are no longer forbidden and reactions may trigger other reactions. Infinite loops are cut in case of the default scheduler, but they may occur for custom schedulers - based on its implementation.

Fixes

  • Nesting reactions works properly from now on.

v4.1.3

24 May 17:28
Compare
Choose a tag to compare

Fixes

  • @BenoitZugmeyer Fixed using none primitive keys in observable ES6 data structures (Map, Set, WeakMap, WeakSet).

v4.1.2

08 Mar 15:31
Compare
Choose a tag to compare

Fixes

  • Improved built-in detection. It should not throw errors for built-ins with internal slots anymore.
  • Do not violate Proxy invariant for none writable, none configurable object valued properties. These are silently not reactive, instead of throwing an error from now on.

v4.1.1

14 Feb 16:39
Compare
Choose a tag to compare

Fixes

  • Fixed an infinite loop issue with the new debugger

v4.1.0

13 Feb 20:29
Compare
Choose a tag to compare

Features

Fixes

  • Added reactivity for has/in operations.
  • Never trigger a reaction more than once for a single operation.
  • Fixed reactivity in case of mutating sparse arrays at an unused index, which is smaller then the arrays length.

Others

  • Removed dynamic type checks, use TypeScript for type safety.

v4.0.1

16 Jan 16:01
Compare
Choose a tag to compare

Fixes

  • Removed package-lock

v4.0.0

13 Jan 17:58
Compare
Choose a tag to compare

Breaking changes

  • Removed unqueue, use the observe scheduler option instead with an add and delete method.
  • Removed exec, observe returns a reaction - that you can call directly - instead.
  • Removed observable.$raw, use the raw(observable) function instead to get the raw object.
  • Reactions are executed synchronously on observable mutations by default. You can get back the old behavior by using a custom scheduler option in observe.
  • Removed nextTick, it is not needed anymore in case of synchronous reaction scheduling.

Features

  • Added the raw function, which returns the raw object when an observable is passed to it.
  • Added a second options argument to observe, which can make it lazy or use a custom reaction scheduler.
  • observe returns a reaction function, which is a transparent proxy of the original function. Call this function, instead of exec(fn).

Fixes

  • DOM Nodes won’t throw when they are wrapped by observables.
  • Out of bound array mutations will correctly trigger length observers.
  • Fixed a memory leak in case of very dynamic functions (lots of conditionals and loops).

v3.1.4

20 Dec 15:30
Compare
Choose a tag to compare

Fixes

  • DOM Nodes remain raw instead of throwing an error, when wrapped in an observable. #14 by @devgrok