Skip to content

Conversation

BlueCutOfficial
Copy link
Contributor

@BlueCutOfficial BlueCutOfficial commented Jun 12, 2025

Context

There's a circular dependency between ember-debug/util/ember and ember-debug/util/ember/loader (a module that customizes how modules are required). It didn't prevent things from working until now, but the situation changed.

As part of implementing Ember + Vite apps support for the inspector, we need to centralize where modules are required in the ember_debug script, so this central system can adjust things depending on the inspected app (what version is it, does it build with Broccoli or Vite?) When we try to implement this centralization, we see the side effects of the circular dependency.

Description

This PR removes ember-debug/util/ember/loader and moves its behavior into ember-debug/util/ember. This change allows us to get rid of the circular dependency that used to exist between these two modules. It also reinforces the role of ember-debug/util/ember as "the file that manages how Ember modules are required".

The other changes in these PRs are all adjustments to the above for all the supported Ember versions. What needs to be imported doesn't include ?.default, and the places that used to import from ember-debug/util/ember/loader now import from ember-debug/util/ember directly.

@BlueCutOfficial BlueCutOfficial marked this pull request as ready for review June 12, 2025 14:59
@BlueCutOfficial BlueCutOfficial requested a review from mansona June 12, 2025 15:07
Copy link
Member

@mansona mansona left a comment

Choose a reason for hiding this comment

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

Fantastic work 🎉

@mansona mansona merged commit 42198be into emberjs:main Jun 12, 2025
20 checks passed
@github-actions github-actions bot mentioned this pull request Jun 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants