Skip to content

fix(compiler-cli): ensure HMR works with different output module type #60797

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

Closed
wants to merge 1 commit into from

Conversation

crisbeto
Copy link
Member

@crisbeto crisbeto commented Apr 9, 2025

Currently when we transpile the HMR update module, we use the project's compiler options verbatim. This appears to break down with some module types, whereas we have to use a native export.

These changes override the compiler options to ensure that the user's options don't end up breaking HMR.

Fixes #60795.

Currently when we transpile the HMR update module, we use the project's compiler options verbatim. This appears to break down with some module types, whereas we have to use a native export.

These changes override the compiler options to ensure that the user's options don't end up breaking HMR.

Fixes angular#60795.
@crisbeto crisbeto added action: review The PR is still awaiting reviews from at least one requested reviewer target: patch This PR is targeted for the next patch release labels Apr 9, 2025
@crisbeto crisbeto requested a review from clydin April 9, 2025 07:08
@angular-robot angular-robot bot added the area: compiler Issues related to `ngc`, Angular's template compiler label Apr 9, 2025
@ngbot ngbot bot added this to the Backlog milestone Apr 9, 2025
@crisbeto crisbeto added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels Apr 9, 2025
atscott pushed a commit that referenced this pull request Apr 9, 2025
…#60797)

Currently when we transpile the HMR update module, we use the project's compiler options verbatim. This appears to break down with some module types, whereas we have to use a native export.

These changes override the compiler options to ensure that the user's options don't end up breaking HMR.

Fixes #60795.

PR Close #60797
@atscott
Copy link
Contributor

atscott commented Apr 9, 2025

This PR was merged into the repository by commit 8744c9a.

The changes were merged into the following branches: main, 19.2.x

@atscott atscott closed this in 8744c9a Apr 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
action: merge The PR is ready for merge by the caretaker area: compiler Issues related to `ngc`, Angular's template compiler target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Hot Module Replacement (HMR) Problems with Module "NodeNext"
4 participants