@codesandbox/sandpack-client
TypeScript icon, indicating that this package has built-in type declarations

2.13.8 • Public • Published

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.

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

Versions

Current Tags

Version History

Package Sidebar

Install

npm i @codesandbox/sandpack-client

Weekly Downloads

69,435

Version

2.13.8

License

Apache-2.0

Unpacked Size

66.6 MB

Total Files

476

Last publish

Collaborators

  • compuives
  • christianalfoni
  • alexnm
  • danilowoz