single-spa-angular icon indicating copy to clipboard operation
single-spa-angular copied to clipboard

Angular application reloads on navigation

Open osamamaruf opened this issue 2 years ago • 2 comments

Demonstration

Issue can be seen by cloning the following repo: https://github.com/osamamaruf/single-spa-angular-reload

Expected Behavior

Screen should not reload on navigation of a lazily loaded module.

https://user-images.githubusercontent.com/34508971/158994834-8981ef44-c5c0-4320-a2fe-adbd16c45329.mp4

Actual Behavior

Screen reloads on navigation of a lazily loaded module.

Specs

  • Angular 8

osamamaruf avatar Mar 18 '22 11:03 osamamaruf

I think this has also something to do with this issue; https://github.com/angular-microfrontends/root-config/issues/7 as due to the reload maybe the platform injector is loaded again. Not sure though.

osamamaruf avatar Mar 18 '22 11:03 osamamaruf

I think this has also something to do with this issue; angular-microfrontends/root-config#7 as due to the reload maybe the platform injector is loaded again. Not sure though.

The error in that example repo comes from:

  1. Trying to share Angular withouth sharing single-spa-angular and single-spa-angular/internals too. See https://github.com/single-spa/single-spa-angular/issues/288#issuecomment-720380317
  2. Trying to share Angular with Ivy which has been a problem. See #370 and #418 .

So, if you are not sharing Angular with Ivy, it should not be the same problem.

OriolInvernonLlaneza avatar Mar 24 '22 16:03 OriolInvernonLlaneza

Closing since I ain't able to divine on videos.

arturovt avatar Mar 28 '23 15:03 arturovt