Single-spa application issue with child app routing

28 Views Asked by At

I have set up a single-spa root-config app and other 2 child apps implemented in angular (using parcels). And I'm trying to navigate to child app routes from root app, it works for the first route /app1, but from that, if I want to navigate to /app1/search or /app1/details it doesn't load the associated component, although url is changed.

If I initially hit /app1/search it loads search component, but after that, if I try to navigate to other routes like /app1/<any-route> it changes the url, but doesn't load the components.

providers: [{ provide: APP_BASE_HREF, useValue: '/app1' }] in app-routing.module.ts

If you set your APP_BASE_URL with / you'll have to add /app1 prefix in all links and routes, but it doesn't work.

0

There are 0 best solutions below