0
votes

I have a parent page kms.html which is loading with router-outlet which loads Login page and my landing page based on login I implemented routing ... now after routing to my landing page which again have router-outlet, in landing component if I write

@RouteConfig([

        { path: '/kms/test', name:'Test', component: testComponent }
    ])

it is throwing an error as Child routes are not allowed for /kms. Use ... on the parent's route path.

If I remove that @RouteConfig part its working fine, but I cannot perform child routing.

Any Clues on this?

1

1 Answers

2
votes

Define the parent's route config like so:

{ path: '/kms/...', component: XXXComponent, as: 'Kms?' }

And in your child's route config only put it like this:

{ path: '/test', name:'Test', component: testComponent }