# @codesandbox/sandpack-client

Latest version **2.19.8** (published 2024-09-12) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @codesandbox/sandpack-client
pnpm add @codesandbox/sandpack-client
yarn add @codesandbox/sandpack-client
bun add @codesandbox/sandpack-client
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; large bundle.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.19.8 |
| Published | 2024-09-12 |
| First published | 2021-03-12 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 6 |
| Unpacked size | 64.1 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 6237 |
| Author | CodeSandbox |
| Maintainers | compuives, christianalfoni, alexnm, danilowoz |

## Links

- npm: https://www.npmjs.com/package/@codesandbox/sandpack-client
- Repository: https://github.com/codesandbox/sandpack
- Homepage: https://github.com/codesandbox/sandpack#readme
- Issues: https://github.com/codesandbox/sandpack/issues
- npm.io page: https://npm.io/package/@codesandbox/sandpack-client

## Dependencies (6)

- [buffer](https://npm.io/package/buffer.md) ^6.0.3
- [dequal](https://npm.io/package/dequal.md) ^2.0.2
- [mime-db](https://npm.io/package/mime-db.md) ^1.52.0
- [outvariant](https://npm.io/package/outvariant.md) 1.4.0
- [@codesandbox/nodebox](https://npm.io/package/@codesandbox/nodebox.md) 0.1.8
- [static-browser-server](https://npm.io/package/static-browser-server.md) 1.0.3

## Recent versions

- 2.19.8 (latest) — 2024-09-12
- 2.0.1-alpha.0 (canary) — 2022-11-25
- 0.1.14-beta.3 (beta) — 2021-10-21
- 2.19.7 — 2024-09-11
- 2.19.4 — 2024-09-10
- 2.19.0 — 2024-08-22
- 2.18.2 — 2024-07-31
- 2.18.1 — 2024-07-25
- 2.18.0 — 2024-07-11
- 2.17.1 — 2024-07-11
- 2.17.0 — 2024-07-09
- 2.16.1 — 2024-07-08
- 2.16.0 — 2024-07-08
- 2.14.5 — 2024-07-03
- 2.14.4 — 2024-06-18
- … 164 more at https://npm.io/package/@codesandbox/sandpack-client/versions

## README

<img style="width:100%" src="https://user-images.githubusercontent.com/4838076/143581035-ebee5ba2-9cb1-4fe8-a05b-2f44bd69bb4b.gif" alt="Component toolkit for live running code editing experiences" />

# Sandpack client 

This is a small foundation package that sits on top of the bundler. It is
framework agnostic and facilitates the handshake between your context and the bundler iframe.

```js
import { loadSandpackClient } from "@codesandbox/sandpack-client";

const main = async () => {
  const client = await loadSandpackClient("#preview", {
    files: {
      "/index.js": {
        code: `console.log(require('uuid'))`,
      },
    },
    entry: "/index.js",
    dependencies: {
      uuid: "latest",
    },
  });
}
```

[Read more](https://sandpack.codesandbox.io/docs/advanced-usage/client)

---
_Source: https://npm.io/package/@codesandbox/sandpack-client · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
