I am using ‘@aurelia/router’ from the v2 beta.
I tried using additiveInstructionDefault: false
That definitely changed the behavior. But now when I click the parent menu item from a child it loads the parent component but with an empty au-viewport. Even if I explicitly set a fallback on the viewport it is still empty. There is no error in the console either.
Do I need to explicitly set something else if I set additiveInstructionDefault to false?
In general it always seems to me that the router is brittle. I am never sure if I am doing things right, the examples are very simple and do not extend to my use cases. As soon as I have components with child routes, things don’t seem to work. ( its probably something on my end that I am not seeing / understanding though )
I will put together a minimal project to test. I am sure I am doing something wrong somewhere.
Here is a StackBlitz example ( forked from @Ivans link above )
The problem that I am having is that I would expect the main menu’s “Artist” link, to take the user to the Artist List page when the user is currently on the Artist Detail page.
to illustrate:
click on the “Artists” link in the top menu
click on either of the two artists to get to the artist detail page
click on the “Artists” link in the top menu again. ( nothing happens )