Skip to content

Astro

Source: src/Prisma/Website/Astro.ts

Astro SSR and prerendered pages on Prisma Compute. The Node target owns the adapter; omit adapter from astro.config.*. Set astro.output to “static” to prerender every page.

Native framework development and HMR run without Prisma cloud resources. Apply Alchemy.remote() to use the live Compute deployment during dev. Packaging requires the optional @vercel/nft peer dependency.

const site = yield* Prisma.Website.Astro("Web", {
rootDir: "./app",
});
const site = yield* Prisma.Website.Astro("Web", {
project,
domain: "www.example.com",
env: { API_BASE: "https://api.example.com" },
compute: { destroyOldDeployment: true },
});
const docs = yield* Prisma.Website.Astro("Docs", {
rootDir: "./docs",
astro: { output: "static" },
assets: { notFoundHandling: "404-page" },
});