T
TanStack7mo ago
multiple-amethyst

How to detect previous route?

I can get to a route from 2 different route, and I want to be able to render the breadcrumb differently. So it would have 3 to 4 items in the breadcrumb depending how I get to that view. Thanks in advance!
4 Replies
flat-fuchsia
flat-fuchsia7mo ago
not really possible unless you record the way yourself you must also think about what shall happen if you enter the page directly via the url? then there is no "history"
multiple-amethyst
multiple-amethystOP7mo ago
I see so would you suggest having 2 separate route then? and they would render different breadcrumb, but the same "view"
flat-fuchsia
flat-fuchsia7mo ago
probably
multiple-amethyst
multiple-amethystOP7mo ago
Thanks mate!

Did you find this page helpful?