Skip to content

Releases: brawaru/async-computed

v5.0.2

28 Feb 17:03
Compare
Choose a tag to compare

5.0.2 (2023-02-28)

Bug Fixes

  • pkg: add missing metadata (493489e)

v5.0.1

04 Jan 00:08
Compare
Choose a tag to compare

5.0.1 (2023-01-04)

Bug Fixes

  • do not cancel on cleanup (13c119e)

v4.0.1

29 Dec 12:54
Compare
Choose a tag to compare

4.0.1 (2022-12-29)

Bug Fixes

  • transform to support environments (23ba56a)

v4.0.0

24 Dec 07:28
Compare
Choose a tag to compare

4.0.0 (2022-12-24)

  • refactor!: improved names and minification (b10676b)

BREAKING CHANGES

  • this change removes and renames some of the public APIs
    therefore not compatible with the previous version. Functionality,
    however, has not been affected and stays the same, so updating process
    comes down to just using new names. The following changes were made:

  • State enum has been removed, Status type is added which describes
    all allowed statuses, which are now regular strings.

  • "resolved" status has been renamed to "fulfilled" to match
    Promises specification, which describes resolved promises as the ones
    in which resolve function has been called, but they're not necessarily
    fulfilled because resolution they may provide could be another Promise
    that has not been resolved to any value. Fulfilled means that Promise
    has finished chained execution and resolved to an actual value, which
    is precisely when we update the object.

  • ResolvedStateObject has been renamed to FulfilledState.

  • StateObjectBase has been renamed to StateBase. The rationale to
    remove 'Object' from names of all state objects was that they're known
    to be objects, so having it a name doesn't provide any meaningful
    information.

  • In StateBase and all of its extends state property has been
    renamed to status, and it is now one of the strings from a union
    type Status.

  • In StateBase and all its extends isPending, isResolved and
    isRejected getters were renamed to pending, fulfilled,
    rejected. It makes usage of those objects in templates and
    conditions look a bit cleaner and makes a bit more sense given that
    isSomething are usually functions that used to describe assertions.

  • StateObject type has been renamed to State.

v3.1.0

24 Dec 07:26
Compare
Choose a tag to compare

3.1.0 (2022-12-24)

Features

  • instantly resolve when getter is not async (f79bf9f)

v3.0.2

23 Dec 05:43
Compare
Choose a tag to compare

3.0.2 (2022-12-23)

Bug Fixes

  • allow thenables to be returned by getter fc (341f477)

v3.0.1

23 Dec 05:37
Compare
Choose a tag to compare

3.0.1 (2022-12-23)

Bug Fixes

  • use sync flush for internal reactor (7cc8da4)

v3.0.0

12 Dec 03:53
Compare
Choose a tag to compare

3.0.0 (2022-12-12)

Bug Fixes

  • remove debug console.log calls (e445532)
  • remove default value for R in asyncComputed (ba2786f)

Features

  • use this to provide abort signal (acbf61d)

BREAKING CHANGES

  • the abort signal is now provided through this

Previously abort signal was provided through arguments and while it
worked for the most part, it made typings more complicated and required
you to use both arguments in getter method definition, even if didn't
want to use the signal. With this change, the signal is now provided
through object that is bound to this on getter calls.

To migrate, simply replace all usages of signal to this.signal, as
well as remove all usages of AsyncComputedOptionsGetterOnly type: it is
removed and merged together into AsyncComputedOptions. If you don't use
watch method or it does not return anything, you can ignore the
source argument passed to the getter method.

v2.0.0

11 Dec 22:54
Compare
Choose a tag to compare

2.0.0 (2022-12-11)

Bug Fixes

  • use 'rejected' for State.Rejected (38faad0)

BREAKING CHANGES

  • State enum value for Rejected changed to 'rejected'

Previously it used 'error', which is a leftover from the previous
iterations of the code. It now uses 'rejected' to match the name of the
enum property and promise terms.

v1.0.0

11 Dec 22:17
Compare
Choose a tag to compare

1.0.0 (2022-12-11)

Features