About
An expandable nested tree for file explorers and folder/document structures, with selection, keyboard navigation, animated branch rows, and RTL-aware connector guide lines.
Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Tree View to your project and fits it to your theme.
Code
How Tree View is used: the demo's code. The component's own source comes with a free account.
Usage.tsx
"use client";
import { TreeView, TreeViewItem } from "@/components/ui/tree-view";
import { DirectionProvider } from "@/components/ui/tree-view-utils/direction";
export default function TreeViewRtlDemo() {
return (
<DirectionProvider locale="ar">
<TreeView aria-label="ملفات المشروع" defaultExpandedKeys={["project"]}>
<TreeViewItem id="project" label="المشروع">
<TreeViewItem id="design" label="التصميم">
<TreeViewItem id="logo" label="الشعار.svg" />
</TreeViewItem>
<TreeViewItem id="notes" label="الملاحظات.md" />
</TreeViewItem>
</TreeView>
</DirectionProvider>
);
}







