Using react-sortable-hoc with react-virtualized Grid

痞子三分冷 提交于 2019-12-07 08:02:28

问题


I want to use react-sortable-hoc with react-virtualized's Grid where the rows are sortable. I cannot use the List as I have multiple columns and I cannot use it with the Table because I have too many columns and therefore need horizontal scrolling.

The issue that I am facing is that the Grid does not have a rowRenderer callback as the Table or List has (it only has cellRenderer and cellRenderer), thus I don't know what to wrap the SortableElement around.

I would appreciate any ideas or examples of this usage?


回答1:


I ended up implementing this as a cellRangeRenderer - see my comment on this GitHub issue: https://github.com/clauderic/react-sortable-hoc/issues/295#issuecomment-344070823



来源:https://stackoverflow.com/questions/46847633/using-react-sortable-hoc-with-react-virtualized-grid

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!