diff --git a/src/lib/cache/http.ts b/src/lib/cache/http.ts index 1f3590c10..c6b764fcf 100644 --- a/src/lib/cache/http.ts +++ b/src/lib/cache/http.ts @@ -9,7 +9,11 @@ export const noCacheFetchOptions: Partial = { // Cloudflare doesn't support the `cache` directive before next-on-pages patches the fetch function // https://github.com/cloudflare/workerd/issues/698 // cache: 'no-store', - next: { revalidate: 0 }, + next: { + revalidate: 0, + // @ts-ignore - experiment to bypass potential I/O sharing in Next + internal: true, + }, }; /** diff --git a/src/lib/images.ts b/src/lib/images.ts index a3e1b2e77..2f65f0b18 100644 --- a/src/lib/images.ts +++ b/src/lib/images.ts @@ -1,5 +1,7 @@ import 'server-only'; +import { noCacheFetchOptions } from '@/lib/cache/http'; + import { rootUrl } from './links'; export interface CloudflareImageJsonFormat { @@ -147,6 +149,7 @@ export async function resizeImage( : `image/${resizeOptions.format || 'jpeg'}`, }, signal, + ...noCacheFetchOptions, }, );