Add nav:false to router-rite redirectTo option?

I have something like this in my router-lite config:

{ path: '', redirectTo: 'home' }

Would it be possible to add in the nav:false property to exclude it from the navigation model?

Current workaround is to just filter the routes array like this:

this.navModel.routes.filter(r => !r.redirectTo)

Hi @ivan! It is already excluded from the nav-model (PR: fix(router-lite): excluded redirectTo from nav-model by Sayan751 · Pull Request #1816 · aurelia/aurelia · GitHub). The fix should be available with the next release. In the meantime, you can use the ‘dev’ version to grab the fix.

3 Likes

That’s great. Thank you.

1 Like