@@ -16,7 +16,6 @@ use turbopack_core::{
1616} ;
1717
1818use crate :: {
19- next_config:: NextConfig ,
2019 next_edge:: entry:: wrap_edge_entry,
2120 pages_structure:: { PagesStructure , PagesStructureItem } ,
2221 util:: { NextRuntime , file_content_rope, load_next_js_template, pages_function_name} ,
@@ -39,7 +38,6 @@ pub async fn create_page_ssr_entry_module(
3938 next_original_name : RcStr ,
4039 pages_structure : Vc < PagesStructure > ,
4140 runtime : NextRuntime ,
42- next_config : Vc < NextConfig > ,
4341) -> Result < Vc < PageSsrEntryModule > > {
4442 let definition_page = next_original_name;
4543 let definition_pathname = pathname;
@@ -169,7 +167,6 @@ pub async fn create_page_ssr_entry_module(
169167 definition_pathname. clone ( ) ,
170168 reference_type,
171169 pages_structure,
172- next_config,
173170 source_query. clone ( ) ,
174171 ) ;
175172 } else {
@@ -213,7 +210,6 @@ async fn wrap_edge_page(
213210 pathname : RcStr ,
214211 reference_type : ReferenceType ,
215212 pages_structure : Vc < PagesStructure > ,
216- next_config : Vc < NextConfig > ,
217213 source_query : RcStr ,
218214) -> Result < Vc < Box < dyn Module > > > {
219215 const INNER : & str = "INNER_PAGE_ENTRY" ;
@@ -223,8 +219,6 @@ async fn wrap_edge_page(
223219 const INNER_ERROR : & str = "INNER_ERROR" ;
224220 const INNER_ERROR_500 : & str = "INNER_500" ;
225221
226- let next_config_val = & * next_config. await ?;
227-
228222 let source = load_next_js_template (
229223 "edge-ssr.js" ,
230224 project_root. clone ( ) ,
@@ -236,9 +230,6 @@ async fn wrap_edge_page(
236230 ( "VAR_MODULE_GLOBAL_ERROR" , INNER_ERROR ) ,
237231 ] ,
238232 & [
239- // TODO do we really need to pass the entire next config here?
240- // This is bad for invalidation as any config change will invalidate this
241- ( "nextConfig" , & * serde_json:: to_string ( next_config_val) ?) ,
242233 (
243234 "pageRouteModuleOptions" ,
244235 & serde_json:: to_string ( & get_route_module_options ( page. clone ( ) , pathname. clone ( ) ) ) ?,
0 commit comments