react-beautiful-dnd and Items with images (async sizing)
See original GitHub issueFirst, thanks for the lib. I’m looking to move from react-virtualized. I’m liking what you have going on here!
I have a list that contains images. Currently, I do not cache the image height in the data payload, just the image URL. When I was following the example at https://virtuoso.dev/react-beautiful-dnd/ it has the whole HeightPreservingItem component with the data-known-size prop. In this example, the component gets measured before the image is loaded, but then after the image loads, there isn’t a resize for that item.
Is there a way you recommend triggering a resize for each item when there is an image load?
Issue Analytics
- State:
- Created 3 years ago
- Comments:13 (6 by maintainers)
Top Results From Across the Web
react-beautiful-dnd and Items with images (async sizing)
I have a list that contains images. Currently, I do not cache the image height in the data payload, just the image URL....
Read more >Dragging not working using SSR after refresh #1854 - GitHub
I should be able to always pick up draggable items. Actual behavior. Receiving the following errors when trying to run react-beautiful-dnd with ...
Read more >How to implement drag and drop in React with React DnD
The most common use cases for drag and drop in React include uploading files, moving items between multiple lists, and rearranging images ......
Read more >Dynamically Update Positions During Drag Using react ...
In this case, it's having the positions of items dynamically display during the drag action, as shown below! Let's get to it! What...
Read more >React beautiful DnD drag out of position problem
Does anyone know why my draggable item gets out of position? The only css I'm using is bootstrap and the ones in my...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

@russelldc thanks. This might be related to the way
mode="virtual"is implemented (as it has react-window as an integration target). I will look into a reliable solution for the content measurement.I did not encounter a problem. Nice to see the new approach works. 👍