Skip to content
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

update ember-concurrency task implementations #7645

Merged

Conversation

stopfstedt
Copy link
Member

@stopfstedt stopfstedt commented Feb 16, 2024

  • convert tasks from modifier, yield syntax to fat-arrow, async/await equivalent
  • in templates, replace perform helper with calls to the perform() method directly on the givens Tasks

on second thought - pass on the perform helper replacement for now.

from the v4.0.0 release notes:

(Not really an enhancement, but) users are encouraged to directly use a task's bound .perform method (and curry with fn helper if needed) rather than to use the classic perform helper, which doesn't really add much value anymore

looking at how pervasive our use of the perform helper throughout common/frontend is, this seems like a pretty big lift without much to gain from at this point.
suggesting we wait until that helper gets deprecated in future versions (having proper deprecation output will make it easier to find and replace anyway).

eslint was coming at us with a "n/no-missing-require" warning.
apparently, it is unable to correctly find this dependency, which is
getting exported out ilios-common and not directly declared in frontend.
so we have to make an exception here.
@stopfstedt stopfstedt requested a review from jrjohnson February 16, 2024 23:29
@stopfstedt stopfstedt marked this pull request as ready for review February 16, 2024 23:29
@stopfstedt stopfstedt removed the request for review from jrjohnson February 16, 2024 23:34
@stopfstedt stopfstedt marked this pull request as draft February 16, 2024 23:34
@stopfstedt stopfstedt requested a review from jrjohnson February 16, 2024 23:40
@stopfstedt stopfstedt marked this pull request as ready for review February 16, 2024 23:40
Copy link
Member

@jrjohnson jrjohnson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Skimmed it, tests pass. 🚀

@jrjohnson jrjohnson merged commit 137bec0 into ilios:master Feb 21, 2024
16 of 19 checks passed
@stopfstedt stopfstedt deleted the ember-concurrency-modern-task-syntax branch December 10, 2024 23:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants