Guides
Framework adapters
Glacier's core is framework-agnostic. Adapters handle the wiring — request context, edge runtime, and lifecycle — so you don't have to.
Next.js
npm i @glacier/next
// next.config.js
const { withGlacier } = require('@glacier/next')
module.exports = withGlacier({
glacier: { edge: true },
})
The Next adapter hooks into both the App Router and route handlers, and runs warming in the edge runtime automatically when edge is on.
Remix
npm i @glacier/remix
import { glacierLoader } from '@glacier/remix'
export const loader = glacierLoader(async ({ params }) => {
return getProject(params.id)
})
Other frameworks
| Framework | Package | Notes |
|---|---|---|
| SvelteKit | @glacier/sveltekit | Hooks into handle and load |
| Astro | @glacier/astro | Middleware integration |
| Express | @glacier/express | Plain middleware for Node servers |
No adapter for your stack?
The core SDK works anywhere JavaScript runs. An adapter only saves boilerplate — you can always call glacier.prefetch() and glacier.invalidate() directly from any handler. See the Architecture guide for the integration surface.