File Diff
A compact code-change surface with old and new line numbers plus live change counts.
Loading component preview…
Installation
Add the component source directly to your project.
pnpm dlx shadcn@latest add https://pastaui.com/r/file-diff.jsonAPI reference
File Diff
| Prop | Type | Default | Description |
|---|---|---|---|
filename | string | — | Names the changed file. |
lines | DiffLine[] | — | Provides context, addition, and deletion rows. |
additions / deletions | number | derived | Overrides calculated change counts. |