# Sandbox Standard 1 - Code and preview

> Sandpack sandbox with code editor and live preview tabs.

A shadcn/ui block from the [@shadcnblocks](https://shadcnblocks.com) registry, listed on [shadcn.exchange](https://shadcn.exchange/r/shadcnblocks/sandbox-sandbox-standard-1).

- Page, with a live preview: https://shadcn.exchange/r/shadcnblocks/sandbox-sandbox-standard-1
- Screenshot: https://abzjhwgwpdpz7ua5.public.blob.vercel-storage.com/shots/shadcnblocks/sandbox-sandbox-standard-1-light-c4b48ca4ae1d8a01.png
- Registry item: https://shadcnblocks.com/r/sandbox-sandbox-standard-1.json
- Listed: 2026-10-13, source last changed 2026-10-13

## Install

```bash
npx shadcn@latest add https://shadcnblocks.com/r/sandbox-sandbox-standard-1.json
```

Run it in a project that has shadcn/ui set up. It adds the files below and installs what they depend on.

## Dependencies

- Registry items: `https://www.kibo-ui.com/r/sandbox.json`

## Files

### `example/sandbox/sandbox-standard-1.tsx`

```tsx
"use client";

import {
  SandboxCodeEditor,
  SandboxLayout,
  SandboxPreview,
  SandboxProvider,
  SandboxTabs,
  SandboxTabsContent,
  SandboxTabsList,
  SandboxTabsTrigger,
} from "@/components/kibo-ui/sandbox";

export const title = "Code and preview";

const Example = () => (
  <SandboxProvider
    className="h-[28rem] w-full max-w-3xl overflow-hidden rounded-lg border"
    files={{
      "/App.js": `export default function App() {
  return <h1 style={{ fontFamily: "sans-serif" }}>Hello from Sandbox</h1>;
}
`,
    }}
    template="react"
  >
    <SandboxLayout>
      <SandboxTabs defaultValue="code">
        <SandboxTabsList>
          <SandboxTabsTrigger value="code">Code</SandboxTabsTrigger>
          <SandboxTabsTrigger value="preview">Preview</SandboxTabsTrigger>
        </SandboxTabsList>
        <SandboxTabsContent value="code">
          <SandboxCodeEditor />
        </SandboxTabsContent>
        <SandboxTabsContent value="preview">
          <SandboxPreview />
        </SandboxTabsContent>
      </SandboxTabs>
    </SandboxLayout>
  </SandboxProvider>
);

export default Example;
```
