Skip to content

Releases: machty/ember-concurrency

2.0.0-rc.1

10 Dec 21:32
Compare
Choose a tag to compare
2.0.0-rc.1 Pre-release
Pre-release

New features

  • Implement decorators from ember-concurrency-decorators (#386). The "nice" decorators
    from ember-concurrency-decorators are now built-in to ember-concurrency, without
    requiring an additional addon or seperate import. All decorators are available for
    import directly from the top-level ember-concurrency package.

    Many thanks to @buschtoens for years of stewardship of that addon, and important contributions from @chancancode for TypeScript support, and others in the community to get it to a place where it's seen wide adoption in the world of Ember Octane, TypeScript, and native ES classes.

    Addon maintainers: Please see notes in UPGRADING-2.x.md if you're using
    decorators currently, and wish to support both ember-concurrency 1.x and 2.x at
    runtime.

Documentation

  • Rewrite documentation to use native classes and decorators, and update tutorial
    to show rewriting of async function code, rather than Promise code, as is more common
    today (#387, #389)

2.0.0-beta.2

03 Nov 02:43
Compare
Choose a tag to compare
2.0.0-beta.2 Pre-release
Pre-release

Enhancements

  • Migrate task lifetimes to @ember/destroyable underneath, rather than
    patching willDestroy (#377).

    Potentially breaking: this drops support for Node 8 and Ember < 3.8 LTS

Bugfixes

  • Ensure encapsulated task state can be accessed on the TaskInstance (#381, #383)

    Note: this uses Proxy and WeakMap, which may need to be polyfilled/unavailable on
    older browsers.

  • Make sure task/group-level state field is tracked (#382)

Removals

  • Drop unused broccoli-file-creator and ember-maybe-import-regenerator
    dependencies.

    Note on ember-maybe-import-regenerator: This was originally added back when
    generator support in browsers was far lower and Babel 5 and 6 were used. The
    addon does nothing for Babel 7, which is used for ember-concurrency these
    days. Tweaking config/targets.js or adding the regenerator Babel plugin to
    your babel config can be done instead if the regenerator runtime is needed
    to transpile generators for older browsers.

Other

  • [dev] Upgrade Ember-CLI to 3.22 (#380)

2.0.0-beta.1

24 Sep 01:38
Compare
Choose a tag to compare
2.0.0-beta.1 Pre-release
Pre-release

Enhancements

  • Port over changes from 1.1.6 through 1.3.0 (#367)

  • Use @tracked underneath on Ember 3.16+ (#354)

    Note: Within applications with both tracked & computed properties,
    if using a native getter to access task state, and wishing to use it
    alongside a computed property, @dependantKeyCompat will need to be used on
    the getter as expected with any other tracked-prop using getter.

Bugfixes

  • Fixes the deprecated -task-property module (for compatibility w/ some
    external addons). TaskProperty is available at the top-level.

Removals

  • Remove ability to directly use tasks with {{action}} helper stuff
    (deprecated in 1.3.0) (#374)
  • Remove get and set compatibility methods from Task, TaskGroup,
    and TaskInstance.

Documentation about upgrading to 2.0.0-beta.1 and other future 2.x releases in
general can be found in UPGRADING-2.x.md

1.3.0

08 Sep 15:43
Compare
Choose a tag to compare

New Features

  • Add animationFrame yieldable helper. Yielding animationFrame() will
    pause a task until after the next animation frame using the native
    requestAnimationFrame() browser API.

    Note: ember-concurrency tasks are scheduled on the runloop, so this will
    not cause the remainder of the task to instead run during the next animation
    frame, but the runloop after the next animation frame. (#365, thanks @Turbo87!)

  • Add hashSettled helper for cancellation-aware implementation of RSVP's hashSettled (#353, thanks @kwliou!)

Bugfixes

  • Add missing types for linked() and unlinked() (Fixes #373)

Deprecations

  • Deprecate direct usage of task with action helper and disable tests for it
    on 3.20+.

    This feature unfortunately depends on private APIs that will be removed in
    Ember 3.25. Unfortunately, the mechanism was already removed in Ember 3.20,
    making it impossible to support this for releases at least until recent
    canaries where it was re-introduced with a deprecation. However, the feature
    is rarely used, only documented in this changelog, and frequently breaks
    whenever the private constant it depends on moves modules internally
    throughout new versions of Ember.

    It will continue to remain available for Ember < 3.20, but will not be
    available in Ember-Concurrency 2.0, and will show a deprecation warning from
    1.3.0 forward.

    Any existing uses can be converted to using {{perform}} directly or
    wrapping the task in (perform) before passing to {{action}} or {{fn}}

    Before:

    <button onClick={{action someTask}}>My button</button>

    After:

    {{!-- Any of these --}}
    <button {{on "click" (perform someTask)}}>My button</button>
    <button onClick={{perform someTask}}>My button</button>
    <button onClick={{action (perform someTask)}}>My button</button>
    <button onClick={{fn (perform someTask)}}>My button</button>

1.2.1

25 Jun 02:26
Compare
Choose a tag to compare

Bugfixes

  • Correct types for encapsulated tasks to allow accessing encapsulated task state (#362, thanks @chancancode!)
  • Correct types to reflect that Task, TaskInstance, and TaskGroup extend EmberObject (#363, thanks @jamescdavis!)

1.2.0

17 Jun 21:50
Compare
Choose a tag to compare

New Features

  • Introduce official TypeScript definitions targeting the last 3 versions of
    TypeScript. A big, big thank you to @chancancode for this heroic effort!
    Also, a thank you to all others before who worked on previous iterations of
    typing experiments for ember-concurrency and provided feedback. If you were
    using one of the community-provided solutions or other custom type definitions,
    you will likely need to remove those and refactor to adhere to the new official
    types.
    (#357)

    For more information about using TypeScript with ember-concurrency, please see the new docs page

1.1.7

28 Mar 02:23
Compare
Choose a tag to compare

Bugfixes

  • Fix waitForProperty on non-EmberObject hosts (i.e. native classes) (#352. Fixes #292. Thanks @andrewfan for the find!)

1.1.6

28 Feb 02:17
Compare
Choose a tag to compare

Enhancements

  • Add support for waitForEvent helper on host objects supporting 'on' API. Previously, waitForEvent only supported DOM-like objects with addEventListener/removeEventListener or jQuery-like objects with one/off, but did not support those with just on/off. (#348. Fixes #164)

2.0.0-alpha.0

02 Feb 23:38
Compare
Choose a tag to compare
2.0.0-alpha.0 Pre-release
Pre-release

Breaking Changes

  • Currently, there are no known breaking changes related to user-facing APIs. Paths to various private modules have changed, so if you were depending on those, they may need to be updated. Please open an issue and let us know what you're using them for.

Enhancements

  • @machty refactored & cleaned up the scheduler and core to rely less on computed properties, and potentially make the core extractable and usable in non-Ember environments. (#302)

Bugfixes

  • Fixes derived state related bugs (#175, #278, potentially more)

Notes

  • This is a pre-release, so we don't necessarily recommend its use in production, but would love your feedback.
  • There may be breaking changes in future 2.0.0 pre-releases.

1.1.5

16 Jan 04:14
Compare
Choose a tag to compare

Bugfixes

  • Avoid auto-tracking rerender assertion / infinite rerender during cancellation in certain contexts in Ember 3.15+ (#341, Fixes #340)