JSON viewer

JSON viewer: A collapsible JSON tree with search, paging for long arrays, and copy value or path. Free MIT React & Next.js source with Motion and Tailwind CSS, live preview, CLI install and docs.

Install JSON viewer

npx motion-ui-skill add json-viewer

Components install as source into your project. The interactive page also includes preview, code, documentation and install tabs.

Dependencies

  • clsx
  • lucide-react
  • motion
  • react
  • tailwind-merge

Source files

JSON viewer

A collapsible JSON tree with search, paging for long arrays, and copy value or path.

Install

npx motion-ui-skill add json-viewer

Dependencies

  • clsx
  • lucide-react
  • motion
  • react
  • tailwind-merge

Usage

"use client";

import { JsonViewer as JsonViewer } from "@/components/agents/json-viewer";

export function Example() {
  return (
    <div className="p-6">
      <JsonViewer />
    </div>
  );
}

Browse this category