Skip to content

[React] Row selection does not reset after upgrading from v7 to v8 #4498

Description

@kabomi

Describe the bug

Hello,

first, thank you for your awesome job, v8 is by far better than v7, I appreciate all the effort you put on it.
I'm pointing this issue as a Bug because I couldn't find any information on the documentation about it, so if it is not a bug, my apologies.

In v7, there was the option autoResetSelectedRows that (it was set by default to true) resets the selected rows whenever the data changes.
In v8, this option is not there anymore and the default behaviour is exactly the opposite.

I would like to know, first, if that was intended, second, if there are plans to restore the configuration option autoResetSelectedRows and when?

A reproducible repo could be found on your documentation pages: https://2llvty.sse.codesandbox.io

Your minimal, reproducible example

https://2llvty.sse.codesandbox.io

Steps to reproduce

Open https://2llvty.sse.codesandbox.io

Select the first 2 rows (checkbox)

Press on refresh data (button) at the bottom

Result:
Data is refreshed and the rows remain selected, even though data did change.

Expected behavior

After data was refreshed, the selection should have been reset, same as it was in v7.

Or there is an option like autoResetSelectedRows that I could set in order to obtain the same behaviour as in v7.

How often does this bug happen?

Every time

Screenshots or Videos

No response

Platform

  • Os: [macOS] - Browser: [Chrome, Firefox]

react-table version

"@tanstack/react-table": "^8.5.22",

TypeScript version

v4.7.3

Additional context

No response

Terms & Code of Conduct

  • I agree to follow this project's Code of Conduct
  • I understand that if my bug cannot be reliable reproduced in a debuggable environment, it will probably not be fixed and this issue may even be closed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions