0

I'm sharing info located on mi RTK store, between two diferentes routes / components.

Each view share the element products, that's why when I go from one route to another, if I search something on route 1, and then I go to route 2 this one still display the search I made on the first one.

I need to clear the store everytime the hash changes, I was thinking on using onHashChange, but I don't know how to apply that to this case inside React.

Image reference from my store

Dereemii
  • 33
  • 1
  • 6

0 Answers0