Components
JSONViewer
Interactive JSON explorer with collapsible nodes and syntax coloring.
Explore JSON data interactively with expand/collapse, keyboard navigation, and syntax coloring.
Installation
Usage
Keyboard Shortcuts
| Key | Action |
|---|---|
↑ / k | Previous node |
↓ / j | Next node |
→ / l / Space | Expand |
← / h | Collapse |
g | First node |
G | Last node |
Color Coding
| Type | Color |
|---|---|
| String | success (green) |
| Number | warning (yellow) |
| Boolean | info (blue) |
| Null | muted |
| Keys | text |
API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
data | any | — | JSON data (required) |
initialDepth | number | 1 | Auto-expand depth |
maxHeight | number | — | Max visible rows |
showTypes | boolean | false | Show type annotations |
showIndices | boolean | true | Show array indices |
rootLabel | string | 'root' | Root node label |
focus | boolean | true | Accept keyboard input |
theme | InkUITheme | darkTheme | Color theme |