-
Notifications
You must be signed in to change notification settings - Fork 12k
feat(@angular-devkit/build-angular): auto configure hot module replacement (HMR) #18788
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
Conversation
packages/angular_devkit/build_angular/src/webpack/plugins/common-js-usage-warn-plugin.ts
Outdated
Show resolved
Hide resolved
|
||
function restoreFormValues(oldInputs, oldOptions) { | ||
// Restore input | ||
const newInputs = document.querySelectorAll('input'); |
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.
What about shadow roots? I don't think this would pick up input elements hidden under a shadow root, though I don't know how commonly those are used in Angular applications.
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.
I don't think it's that common, I don't want to add complexity and use-cases to support just for the sake of it. I think we can evaluate shadow root based on the community feedback.
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.
I'm fine to defer it, though we may want to document that limitation somewhere.
…ement (HMR) With this change we configure HMR internally and therefore users which want to use basic HMR functionality will not longer be required to change their application code. This is important because previously a lot of users missed out on HMR or reported a broken behaviour. This also gives novice users a better chance to appreciate HMR and Angular because of the zero effort required to use HMR. Closes #17324
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
With this change we configure HMR internally and therefore users which want to use basic HMR functionality will not longer be required to change their application code.
This is important because previously a lot of users missed out on HMR or reported a broken behaviour. This also gives novice/new users a better chance to appreciate HMR and Angular because of the zero effort required to use HMR.
Closes #17324