Pass property using navigateTo
I have a list where each item is clickable. I would like to pass a property (string) that has been fetched and pass it to the page that
navigateTo
navigates. It's [...slug]
and I would like to access that property there (if value exists). Could anyone please give me a hint how to achieve that?6 Replies
Sounds like you just want to add a query param to the navigateTo?
Thank you for the reply. This approach won't work sadly because the string has some words... so I believe that the URL limit would be reached (in some cases). Sorry for not including that inside of the question.
Hmm maybe
useState
may be the easiest option? There's no other way through navigateTo as far as I'm awareyou can use route states;
this state can then be accessed from;
That's nice I didn't know that thank you !
Perfect. Thank you! ❤️