1 /**
2 * The `@opennextjs/cloudflare/overrides/*` specifiers are defined through the
3 * package's `exports` map, which the `node` (node10) moduleResolution used by
4 * this app can't read. These shims point TypeScript at the physical files;
5 * the OpenNext build resolves the real specifiers through the exports map.
6 */
7 declare module "@opennextjs/cloudflare/overrides/incremental-cache/r2-incremental-cache" {
8 export * from "@opennextjs/cloudflare/dist/api/overrides/incremental-cache/r2-incremental-cache"
9 export { default } from "@opennextjs/cloudflare/dist/api/overrides/incremental-cache/r2-incremental-cache"
10 }
11
12 declare module "@opennextjs/cloudflare/overrides/incremental-cache/regional-cache" {
13 export * from "@opennextjs/cloudflare/dist/api/overrides/incremental-cache/regional-cache"
14 }
15
16 /**
17 * Structural typing for the ASSETS binding, since `@cloudflare/workers-types`
18 * isn't installed. Merged into the CloudflareEnv interface that
19 * `getCloudflareContext().env` is typed with.
20 */
21 interface CloudflareEnv {
22 ASSETS?: {
23 fetch(url: string | URL): Promise<Response>
24 }
25 }