#multiple paginated tables - how to handle search params

1 messages · Page 1 of 1 (latest)

low fern
#

So my issue is I’ve got a page with a table of users on it. And an outlet modal that’s got another table of users. Both are paginated and use a common component that just updated the route with the ?page search param. So paginating the modal paginates the parent table also.

I’m thinking the only solution is to pass in some kind of optional identifier to the footer like a name and have it append that the the search param. Can anyone recommend anything cleaner though?

steady vortex
#

You need to somehow namespace the search params for each table

#

?page[table1]=2&page[table2]=5

low fern
#

Yeah that’s what I was thinking 😢 I guess I can just let the footer component accept an identifier prop and handle it that way