|
1 |
| -import { NextjsAppPaths } from "../../nextjsPaths"; |
| 1 | +import { NextjsAppPaths } from "../../nextjs-paths"; |
2 | 2 | import { build, Plugin } from "esbuild";
|
3 | 3 | import { readdirSync, readFileSync, writeFileSync } from "node:fs";
|
4 | 4 | import { cp, readFile, writeFile } from "node:fs/promises";
|
5 | 5 |
|
6 |
| -import { patchRequire } from "./patches/investigated/patchRequire"; |
7 |
| -import { patchUrl } from "./patches/investigated/patchUrl"; |
8 |
| -import { copyTemplates } from "./patches/investigated/copyTemplates"; |
| 6 | +import { patchRequire } from "./patches/investigated/patch-require"; |
| 7 | +import { patchUrl } from "./patches/investigated/patch-url"; |
| 8 | +import { copyTemplates } from "./patches/investigated/copy-templates"; |
9 | 9 |
|
10 |
| -import { patchReadFile } from "./patches/to-investigate/patchReadFile"; |
11 |
| -import { patchFindDir } from "./patches/to-investigate/patchFindDir"; |
12 |
| -import { inlineNextRequire } from "./patches/to-investigate/inlineNextRequire"; |
13 |
| -import { inlineEvalManifest } from "./patches/to-investigate/inlineEvalManifest"; |
14 |
| -import { patchWranglerDeps } from "./patches/to-investigate/wranglerDeps"; |
| 10 | +import { patchReadFile } from "./patches/to-investigate/patch-read-file"; |
| 11 | +import { patchFindDir } from "./patches/to-investigate/patch-find-dir"; |
| 12 | +import { inlineNextRequire } from "./patches/to-investigate/inline-next-require"; |
| 13 | +import { inlineEvalManifest } from "./patches/to-investigate/inline-eval-manifest"; |
| 14 | +import { patchWranglerDeps } from "./patches/to-investigate/wrangler-deps"; |
15 | 15 |
|
16 | 16 | /**
|
17 | 17 | * Using the Next.js build output in the `.next` directory builds a workerd compatible output
|
@@ -92,6 +92,8 @@ export async function buildWorker(
|
92 | 92 | globalThis.__dirname ??= "";
|
93 | 93 |
|
94 | 94 | // Do not crash on cache not supported
|
| 95 | +// https://github.com/cloudflare/workerd/pull/2434 |
| 96 | +// compatibility flag "cache_option_enabled" -> does not support "force-cache" |
95 | 97 | let isPatchedAlready = globalThis.fetch.__nextPatched;
|
96 | 98 | const curFetch = globalThis.fetch;
|
97 | 99 | globalThis.fetch = (input, init) => {
|
|
0 commit comments