How to pass data from Parent app to Child app through binding parameter to the URL in Single SPA Angular?

I have created two apps. One is the parent app and another one is the child app. Now suppose I have created one product component in the parent app and defined the path inside the routing file.

{ path: 'product/:appId', component: ProductComponent }

so here I am mounting my child app inside the product component, and inside app.component.ts file I am like navigating to product component using router for example:

ngOnInit(): void {
  this.router.navigate(['/product', 'mockApp1']);
}

My parent app is running on port:4200 and the child app on port: 4201. So basically if I will type "http://localhost:4200/product/mockApp1" then it will load our child app inside the parent app and where "mockApp1" is our app id.

So now I want to access this app id inside the child app which I am passing through URL in the parent app so is it possible to get this app id inside the child application. if it is possible then how can I achieve it?

Thanks

How many English words
do you know?
Test your English vocabulary size, and measure
how many words do you know
Online Test
Powered by Examplum