React infinite scroll scrollableTarget get id dynamically?

后端 未结 1 1184
后悔当初
后悔当初 2021-01-24 00:48

I use react-infinite-scroll-component in my project. How can I make scrollableTarget dynamically get item id? I\'ve tried like this scrollableTarget={item.id} but i

1条回答
  •  孤独总比滥情好
    2021-01-24 01:25

    the problem is solved like this scrollableTarget={item.id.toString()}

    0 讨论(0)
提交回复
热议问题