Skip to content

State

Parameters passed to callbacks when data changes in the list.

Type ParameterDefault typeDescription
DataanyThe type of the data items in the list.

optional autoscrollToBottomBehavior: ScrollBehavior | { location: () => ItemLocation | null | undefined; }


Data


The shape of the message list data prop. It includes the data to render and any extra scroll position modification that should be applied when the data changes.

Type ParameterDescription
DataThe type of the data items in the list.

Data[] | null | undefined



Describes the location of the list relative to the viewport and the scroll element.

number

The distance between the scroller element bottom edge and the viewport bottom edge. If 0, the list is at the bottom.


boolean

A convenience flag that indicates whether the list is at the bottom. The flag is also true when the list is currently scrolling to the bottom.


number

The distance between the list top edge and the viewport top edge. When the list is above the viewport (when scrolling down), this value is a negative number. When the list is scrolled to the top, this value is 0.


number

The scroll height of the scroller wrapper.


number

The height of the visible portion of the list without any headers and footers.