input form updates search params
Answered
Northern Inuit Dog posted this in #help-forum
Northern Inuit DogOP
I have an input box that submits on enter and it’s meant to update the search param.
The url /dashboard/explore?collection=0x84773926638933763 is meant to make a fetch call if the collection exists or simply show the search input if no collection is defined.
What’s the idiomatic way such that upon updating the input field on enter, it updates the collection and makes another fetch.
Validation of collection is done client side and server side.
Would input use a server action? If not, if I need to make an api route, then would the parent also make an route handler call?
The url /dashboard/explore?collection=0x84773926638933763 is meant to make a fetch call if the collection exists or simply show the search input if no collection is defined.
What’s the idiomatic way such that upon updating the input field on enter, it updates the collection and makes another fetch.
Validation of collection is done client side and server side.
Would input use a server action? If not, if I need to make an api route, then would the parent also make an route handler call?
Answered by joulev
3 Replies
Northern Inuit DogOP
Perfect! Ty!
That was quick! Ty so much @joulev