Prevent search params from being inherited?
Can I make search params not being inherited in nested routes? I have a page /files which receives a bunch of search params for filtering and ordering files. Then I have a route /files/$fileId and it makes no sense to have search params for that route.
4 Replies
other-emerald•9mo ago
search params cannot be NOT inherited
but you probably need an index route that has the search params
instead of defining them on /files
then they are not inherited since the index and $fileId are siblings
harsh-harlequinOP•9mo ago
Is this possible with the file based routing method?
other-emerald•9mo ago
of course
harsh-harlequinOP•9mo ago
Thanks, I'll try this 🙂