I have set up my app so that I have a Recipe Book
which has a list of Recipies
which when I click on a Recipe it then shows the Recipe Details
This route is invalid and you should get an error for it.
{ path: '' },
A route either needs to have a component
, a redirectTo
, or children
.
If an empty path route has no children it also should have pathMatch: 'full'
.
I guess what you want is
{ path: '', component: DummyComponent, pathMatch: 'full' },
Where DummyComponent
is a component with an empty view.
You can reuse the same DummyComponent
for all these paths.