Skip to content

Remove traces of "Ember.run" in run-loop.md #2104

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

johanrd
Copy link

@johanrd johanrd commented Mar 26, 2025

Not sure. I know that using the ember runloop is not-recommended in the first place, but when separating out that as a concern: Importing from global Ember is deprecated long time ago.

Not sure what to do about the example use ofEmber.run.hasOpenRunloop() as that seems undocumented / untyped / unexported / archaic to me.

Not sure, but Importing Ember global this is deprecated long time ago.

Not sure what to do about the example use of`Ember.run. hasOpenRunloop()` as that seems undocumented / untyped / unexported / archaic to me.
Copy link

netlify bot commented Mar 26, 2025

Deploy Preview for ember-guides ready!

Name Link
🔨 Latest commit 501e908
🔍 Latest deploy log https://app.netlify.com/sites/ember-guides/deploys/67e3bfee48336a0008253e92
😎 Deploy Preview https://deploy-preview-2104--ember-guides.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

window.addEventListener('online', () => {
// 1. autoruns do not change the execution of arbitrary code in a callback.
// This code is still run when this callback is executed and will not be
// scheduled on an autorun.
console.log('Doing things...');

Ember.run.schedule('actions', () => {
schedule('actions', () => {
// 2. schedule notices that there is no currently available run loop so it
// creates one. It schedules it to close and flush queues on the next
// turn of the JS event loop.
if (! Ember.run.hasOpenRunLoop()) {
Copy link
Author

@johanrd johanrd Mar 26, 2025

Choose a reason for hiding this comment

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

not sure what to do about this example of Ember.run.hasOpenRunloop() – the method seems undocumented / untyped / without public export / archaic to me.

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.

1 participant