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

useSortable data prop is spreaded and hence only copies owned properties. #1375

Open
Rohitbels opened this issue Mar 28, 2024 · 0 comments · May be fixed by #1376
Open

useSortable data prop is spreaded and hence only copies owned properties. #1375

Rohitbels opened this issue Mar 28, 2024 · 0 comments · May be fixed by #1376

Comments

@Rohitbels
Copy link

Rohitbels commented Mar 28, 2024

useSortable data prop is spread and used internally.

spread parameter leads to loss of properties from the prototype chain of an object.

Can we use Object.create?
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/getOwnPropertyDescriptors#creating_a_shallow_copy

@Rohitbels Rohitbels changed the title useSortable data prop is spread and used internally should use Object.assign useSortable data prop is spreaded and hence only copies owned properties. Mar 28, 2024
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

Successfully merging a pull request may close this issue.

1 participant