Skip to main content
196

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
React Native docs
Data displayReact Native

Tree

Browse hierarchical records with controlled disclosure and selection.

Public APILumenTreeReact Native

Native example

Use Tree

Use stable flat graph identities. Invalid graphs fail closed; state edits retain unknown host IDs. Read-only selection still permits disclosure. Localize depth and disclosure formatters.

View captured React Native example
Tree rendered in the Expo web renderer Lumen playground
Captured exampleExpo web renderer
tsx
<LumenTree label="Files" nodes={nodes} expandedIds={expanded} onExpandedChange={setExpanded} selectedIds={selected} onSelectionChange={setSelected} />

Reference

Public API

The primary shared and platform-specific options exposed by LumenTree.

APIValues or typeDefaultDescription
nodesLumenTreeNode recordsRequiredDefines stable identity, parent, label and disabled/selectable state.
expandedIds / selectedIdsControlled setsRequired expansion / optional selectionPreserves host state through hidden and unavailable nodes.
loading / error / readOnlyPlatform state valuesReady / no error / editableHides stale controls during result states and guards mutations.

Native behavior

Design and accessibility

When to use it

Use stable flat graph identities. Invalid graphs fail closed; state edits retain unknown host IDs. Read-only selection still permits disclosure. Localize depth and disclosure formatters.

Accessibility

Localized disclosure and depth with native selection controls and inherited disabled state.

Shared component

Available on other platforms

Apple / SwiftUIAndroid / Compose
React Native docsNative primitives