Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to disable column order preserving #693

Open
jared-jewitt opened this issue Jan 30, 2025 · 0 comments
Open

Add option to disable column order preserving #693

jared-jewitt opened this issue Jan 30, 2025 · 0 comments

Comments

@jared-jewitt
Copy link

Is your feature request related to a problem? Please describe.

It looks like in order for column dragging to work, a storeColumnsKey must be supplied to the table. This works fine, however I have a table in which users can dynamically add columns. When these columns are added by the user, I'd prefer for them to be rendered in the order specified in the columns array in the useDataTableColumns hook. Instead, they are always added to the right side of the table. I have a pinned ellipsis menu as the last column, and it would be nice to have it stay there when new columns are added.

Describe the solution you'd like

Perhaps introduce a new prop (preserveColumnOrder?) where users could set to false if they want to opt out of this default behaviour.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant