Set up your framework
Use Startpod's Vite or Next.js integration to configure browser isolation.
Startpod includes its workers and WebAssembly toolchain. Add the integration for your host framework so your application receives the browser isolation headers Startpod needs.
Vite
import { defineConfig } from "vite"
import { startpod } from "startpod/vite"
export default defineConfig({
plugins: [startpod()],
})The plugin configures the development server and copies the packaged assets
used by local development. Keep Vite's publicDir enabled.
Next.js
import { withStartpod } from "startpod/next"
const nextConfig = {}
export default withStartpod(nextConfig)The wrapper copies packaged assets to public and merges Startpod's response
headers with those already configured by your application.
For Safari support, configure the host with require-corp:
startpod({ coep: "require-corp" })
// or
withStartpod(nextConfig, { coep: "require-corp" })Applications deployed below /
The managed runtime uses its own origin, so your host application's Vite base
or Next.js basePath does not change the Startpod.init() call.
Production headers
The integrations configure local development. Your production host must preserve the same COOP, COEP, and CORP headers. See Configure isolation headers for the required values.
The generated __startpod assets belong to the installed package. Do not edit
them or install their compiler packages separately.