Answered by
franky47
Dec 9, 2023
Replies: 2 comments
|
Update! I managed to make it work with this buuut now there is another problem in my home page I have a slider with the brands and it is supposed to sent you to http://localhost:3000/tienda?brands=QUIMECO it does, but "QUIMECO" appears 1 second and then vanish |
0 replies
|
In your original post you show code using React's Note that since you're working with arrays, the import { useQueryState, parseAsArrayOf, parseAsString } from 'next-usequerystate'
const [brands, setBrands] = useQueryState(
'brands',
parseAsArrayOf(parseAsString)
.withDefault([brands])
) |
0 replies
Answer selected by
franky47
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment


In your original post you show code using React's
useState, could you show us the relevantuseQueryStatehook please?Note that since you're working with arrays, the
parseAsArrayOfparser may help with query string formatting here: