add cloudflare workers support (#326)

This commit is contained in:
Aman Varshney
2025-06-16 22:55:26 +05:30
committed by GitHub
parent 5fc1ba164e
commit b34e94a09e
34 changed files with 556 additions and 538 deletions

View File

@@ -818,4 +818,17 @@ export async function handleExtras(
await processTemplate(npmrcTemplateSrc, npmrcDest, context);
}
}
if (context.runtime === "workers") {
const runtimeWorkersDir = path.join(PKG_ROOT, "templates/runtime/workers");
if (await fs.pathExists(runtimeWorkersDir)) {
await processAndCopyFiles(
"**/*",
runtimeWorkersDir,
projectDir,
context,
false,
);
}
}
}