inveniosoftware / react-searchkit

React component library for interacting with a REST API.
https://inveniosoftware.github.io/react-searchkit/
MIT License
78 stars 40 forks source link

fix sort state #164

Closed FlorianCassayre closed 3 years ago

FlorianCassayre commented 3 years ago

Tested on ILS, also made sure that it didn't break the history feature. Now:

FlorianCassayre commented 3 years ago

The flag "the user has changed sorting" now behaves as a computed property, depending on whether the sorting parameters appear in the url or not. Previously there was one side-effect: if the user reloaded the page then it would be assumed that the sorting had changed (because the parameter was in the url).

I left the other commit as a reference, but feel free to fixup or ask me to do it.

ntarocco commented 3 years ago

Closed in favor of: https://github.com/inveniosoftware/react-searchkit/pull/166