-
Notifications
You must be signed in to change notification settings - Fork 184
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Drop @ember/render-modifiers
#714
Drop @ember/render-modifiers
#714
Conversation
…to a plain modifier
…difiers to a plain modifier
…ers to a plain modifier
…odifier to a plain modifier
} | ||
} | ||
// @ts-ignore | ||
}, { eager: false }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All modifier()
invocations must include { eager: false }
since this package supports ember-modifier
v3.2.x and v4.
For apps using v3.2.x { eager: false }
will ensure the default autotracking behaviour (eager).
For apps using v4 this argument will be ignored.
// Escape autotracking frame and avoid backtracking re-render | ||
Promise.resolve().then(() => { | ||
this.args.dropdown.actions.reposition() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the only code change I made. Since the did-insert
modifier did not participate in auto tracking this was not an issue before.
I'm reasonably confident that this change is compatible since the tests pass. If this modifier doesn't run a number of tests will fail.
Someone more familiar with this library may have a better suggestion to replacing this operation with a derived data pattern (since this is a side-effect type modifier).
@mkszepp would you mind reviewing this? |
@gilest sry for my delay. it looks good. Thanks |
Replaces the no-longer-recommended render lifecycle modifiers with local function modifiers.
@ember/render-modifiers
were meant as a transitional tool from the pre-Octane era, and not long-term usage.Modifier code is directly ported from the setup/teardown hooks with no changes except what I've pointed out in code comments.
Recommend reviewing commit-by-commit.