Skip to content

Disable modifier auto-tracking. - #16

Merged
rwjblue merged 2 commits into
emberjs:masterfrom
rwjblue:disable-auto-tracking
Oct 3, 2019
Merged

Disable modifier auto-tracking.#16
rwjblue merged 2 commits into
emberjs:masterfrom
rwjblue:disable-auto-tracking

Conversation

@rwjblue

@rwjblue rwjblue commented Oct 2, 2019

Copy link
Copy Markdown
Member

The original RFC specifically defines when these modifier methods should be called, and in all scenarios the semantics of when to re-fire (only applicable to did-update) exclude auto-tracking.

did-insert

From the RFC:

This modifier is activated only when The element is inserted in the DOM.

did-update

From the RFC:

This modifier is activated only on updates to it's arguments (both positional and named). It does not run during or after initial render, or before element destruction.

will-destroy

From the RFC

This modifier is activated:

  • immediately before the element is removed from the DOM.

The original RFC specifically defines when these modifier methods should
be called, and in all scenarios the semantics of when to re-fire (only
applicable to `did-update`) exclude auto-tracking.

did-insert
----------
[From the
RFC](https://github.com/emberjs/rfcs/blob/master/text/0415-render-element-modifiers.md#did-insert):

> This modifier is activated only when The element is inserted in the DOM.

did-update
----------

[From the
RFC](https://github.com/emberjs/rfcs/blob/master/text/0415-render-element-modifiers.md#did-update):

> This modifier is activated only on updates to it's arguments (both
> positional and named). It does not run during or after initial render,
> or before element destruction.

will-destroy
------------

[From the
RFC](https://github.com/emberjs/rfcs/blob/master/text/0415-render-element-modifiers.md#will-destroy)

> This modifier is activated:
>
> - immediately before the element is removed from the DOM.
@rwjblue rwjblue added the bug Something isn't working label Oct 2, 2019
@rwjblue
rwjblue requested a review from pzuraq October 2, 2019 21:31
@rwjblue

rwjblue commented Oct 2, 2019

Copy link
Copy Markdown
Member Author

CI is failing on Node 6 due to socketio/engine.io#589.

@rwjblue
rwjblue merged commit 681946f into emberjs:master Oct 3, 2019
@rwjblue
rwjblue deleted the disable-auto-tracking branch October 3, 2019 13:24
@jordpo

jordpo commented Oct 3, 2019

Copy link
Copy Markdown

awesome!

@barryofguilder

Copy link
Copy Markdown

This couldn't have been merged at a better time. We were running into infinite loops with did-update in our app and couldn't figure out why. This PR fixed it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants