Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/keywork/middleware/classes/WorkerSitesAssetRouter.ts>WorkersSiteStaticContentBinding

A library for building V8 Isolate web apps on Cloudflare Workers, Deno, and Node.JS
Latest
interface WorkersSiteStaticContentBinding
import { type WorkersSiteStaticContentBinding } from "https://deno.land/x/keywork@v6.2.1/middleware/classes/WorkerSitesAssetRouter.ts";

An environment binding available within Worker Sites. This is often used with the @cloudflare/kv-asset-handler package.

This binding only exists in Worker Sites. Cloudflare Pages instead uses env.ASSETS

When using ESBuild, ensure that the virtual module __STATIC_CONTENT_MANIFEST is marked as external:

import {build} from 'esbuild'

build({ external: ['__STATIC_CONTENT_MANIFEST']})

For usage with TypeScript, you'll need to define a module type as well:

// types/cloudflare-worker.d.ts
declare module '__STATIC_CONTENT_MANIFEST'

Properties

__STATIC_CONTENT: KVNamespace