コンテンツにスキップ

SiteKit Cloudflare Adapters

Site developers use these adapters to connect the framework’s public site and editing contracts to Cloudflare storage and event services.

Keep Cloudflare bindings and credentials outside browser code and the generic core. Use D1/R2 projections as rebuildable read models when an upstream publishing system owns content. Use the independent editing provider for host-owned content, with authentication and tenant authorization supplied explicitly by the server.

  • Revisioned D1/R2 snapshot staging, promotion and rollback.
  • D1 Markdown draft saving and publishing through an injected authorization boundary.
  • Optional commerce, media, experiment and social outbox adapters.
  • Queue and Analytics Engine event sinks.

Use Node.js 24+ and Bun 1.4.0. Framework registry publication is pending; install both local artifacts from the same verified source candidate. The structural parser below needs no live Cloudflare bindings.

ターミナルウィンドウ
bun add ./alneas-sitekit-cloudflare-0.1.0.tgz ./alneas-sitekit-0.1.0.tgz astro
import { parseCloudflareSnapshotManifest } from '@alneas/sitekit-cloudflare';
const manifest = parseCloudflareSnapshotManifest({
schemaVersion: '1', siteId: 'example', revision: 'cms-1',
generatedAt: '2026-01-01T00:00:00Z',
contentVersion: 'cms-1', mediaVersion: 'cms-1',
checksum: 'structural-example-only', locales: ['en', 'ja'],
});
console.log(manifest.revision); // cms-1