Skip to content

Commit d5de3a4

Browse files
authored
add worker condition to edge compilation (vercel/turborepo#3549)
some packages expect `worker` or `browser` condition to work on edge runtime
1 parent 1b2a240 commit d5de3a4

File tree

1 file changed

+1
-1
lines changed
  • packages/next-swc/crates/next-core/src/next_edge

1 file changed

+1
-1
lines changed

packages/next-swc/crates/next-core/src/next_edge/context.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ pub async fn get_edge_resolve_options_context(
3131

3232
let resolve_options_context = ResolveOptionsContext {
3333
enable_node_modules: true,
34-
custom_conditions: vec!["development".to_string()],
34+
custom_conditions: vec!["worker".to_string(), "development".to_string()],
3535
import_map: Some(next_edge_import_map),
3636
module: true,
3737
..Default::default()

0 commit comments

Comments
 (0)