You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Include relevant code or preferably a code sandbox
Describe the bug
Using defaultSortFieldId with server side sorting still appears to trigger the build-in client side sorting.
To Reproduce
Create a server side sorting table and set defaultSortFieldId.
See that the selected column is not sorted like the data that is passed in, but sorted by the internal sorting.
Manually specifying a sortingFunction that simply copies the data fixes the issue.
Expected behavior
The internal sorting should never be triggered when sortServer is enabled.
Issue Check list
styled-components
Describe the bug
Using
defaultSortFieldId
with server side sorting still appears to trigger the build-in client side sorting.To Reproduce
Create a server side sorting table and set
defaultSortFieldId
.See that the selected column is not sorted like the data that is passed in, but sorted by the internal sorting.
Manually specifying a sortingFunction that simply copies the data fixes the issue.
Expected behavior
The internal sorting should never be triggered when
sortServer
is enabled.Code Sandbox, Screenshots, or Relevant Code
https://codesandbox.io/s/react-data-table-sandbox-forked-754lb?file=/src/index.js
Runtime is sorted client side here even though
sortServer
is on.Versions (please complete the following information)
See Codesandbox
The text was updated successfully, but these errors were encountered: