It appears that Angular 11 has some breaking changes with HMR. This causes an error to be thrown when .destroy() is called in angular-hmr here. It appears that the error is originating from angular/core here. I am not sure about the cause of the change, but my guess is that Angular is now calling the destroy method itself, before angular-hmr would.
Simply removing this call (as suggested in this PR) appears to fix the issue, and HMR appears to be working fine. I have proposed a version bump, as I would guess that this change is breaking for versions of Angular <11.
Unknowns:
I am not aware of what other implications this change might have (e.g. in use cases other than mine).
I upgraded from Angular 9 to 11, so I am not sure with the implications are for Angular 10.
It appears that Angular 11 has some breaking changes with HMR. This causes an error to be thrown when
.destroy()
is called inangular-hmr
here. It appears that the error is originating fromangular/core
here. I am not sure about the cause of the change, but my guess is that Angular is now calling the destroy method itself, beforeangular-hmr
would.Simply removing this call (as suggested in this PR) appears to fix the issue, and HMR appears to be working fine. I have proposed a version bump, as I would guess that this change is breaking for versions of Angular <11.
Unknowns: