chat list experiment

This commit is contained in:
Logan Allen 2020-08-05 12:19:35 -07:00
parent 3ce70b8264
commit a6981afb5b

View File

@ -34,13 +34,15 @@ export default class ChatList extends Component {
<DynamicSizeList
height={props.height}
width={props.width}
itemCount={props.messages.length}>
itemCount={props.messages.length}
itemData={props.messages}
overscanCount={0}>
{ forwardRef((pro, ref) => (
<ChatMessage
ref={ref}
previousMsg={props.messages[pro.index - 1]}
nextMsg={props.messages[pro.index + 1]}
msg={props.messages[pro.index]}
previousMsg={pro.data[pro.index - 1]}
nextMsg={pro.data[pro.index + 1]}
msg={pro.data[pro.index]}
index={pro.index}
contacts={props.contacts}
/>