mirror of
https://github.com/LukeHagar/vercel.git
synced 2025-12-11 04:22:13 +00:00
[node][remix] Update nft conditions to include "edge-light" for Edge Functions (#9700)
This commit is contained in:
@@ -175,7 +175,9 @@ async function compile(
|
||||
return source;
|
||||
}
|
||||
|
||||
const conditions = isEdgeFunction ? ['worker', 'browser'] : undefined;
|
||||
const conditions = isEdgeFunction
|
||||
? ['edge-light', 'browser', 'module', 'import', 'require']
|
||||
: undefined;
|
||||
|
||||
const { fileList, esmFileList, warnings } = await nodeFileTrace(
|
||||
[...inputFiles],
|
||||
|
||||
@@ -540,7 +540,7 @@ async function createRenderEdgeFunction(
|
||||
const trace = await nodeFileTrace([handlerPath], {
|
||||
base: rootDir,
|
||||
processCwd: entrypointDir,
|
||||
conditions: ['worker', 'browser'],
|
||||
conditions: ['edge-light', 'browser', 'module', 'import', 'require'],
|
||||
async readFile(fsPath) {
|
||||
let source: Buffer | string;
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user