Skip to content

Presence list

Animates list items when you add, remove, or move them.

  • 01Review copy
  • 02Check icons
2 remaining
presence-list-basic-demo.tsx

Installation

The CLI adds the files, packages, theme variables, and Tailwind plugin that this component uses. Before you run it, set up your project.

Adding and reordering

Pass getKey so rows keep their identity when they enter, leave, or move.

  • First item
  • Second item
  • Third item
presence-list-demo.tsx

API reference

items: readonly T[]Required
Items to show in the list.
getKey: (item: T) => string | numberRequired
Returns a unique key for an item. Keep the key the same while the item is in the list.
children: (item: T) => ReactNodeRequired
Renders the content of each list item. Move focus before you remove a focused item.