1
1
use anyhow:: { Context , Result } ;
2
2
use indoc:: formatdoc;
3
- use turbo_tasks:: { TryJoinIterExt , Value , ValueToString , Vc } ;
3
+ use turbo_tasks:: { TryJoinIterExt , ValueToString , Vc } ;
4
4
use turbopack_binding:: {
5
5
turbo:: tasks_fs:: FileSystemPath ,
6
6
turbopack:: {
7
7
core:: {
8
8
asset:: { Asset , AssetContent } ,
9
9
chunk:: {
10
- availability_info :: AvailabilityInfo , Chunk , ChunkData , ChunkItem , ChunkItemExt ,
11
- ChunkableModule , ChunkableModuleReference , ChunkingContext , ChunkingContextExt ,
12
- ChunkingType , ChunkingTypeOption , ChunksData ,
10
+ ChunkData , ChunkItem , ChunkItemExt , ChunkType , ChunkableModule ,
11
+ ChunkableModuleReference , ChunkingContext , ChunkingContextExt , ChunkingType ,
12
+ ChunkingTypeOption , ChunksData ,
13
13
} ,
14
14
ident:: AssetIdent ,
15
15
module:: Module ,
@@ -18,11 +18,11 @@ use turbopack_binding::{
18
18
reference:: { ModuleReference , ModuleReferences , SingleOutputAssetReference } ,
19
19
resolve:: ModuleResolveResult ,
20
20
} ,
21
- ecmascript:: chunk:: EcmascriptChunkData ,
21
+ ecmascript:: chunk:: { EcmascriptChunkData , EcmascriptChunkType } ,
22
22
turbopack:: ecmascript:: {
23
23
chunk:: {
24
- EcmascriptChunk , EcmascriptChunkItem , EcmascriptChunkItemContent ,
25
- EcmascriptChunkPlaceable , EcmascriptChunkingContext , EcmascriptExports ,
24
+ EcmascriptChunkItem , EcmascriptChunkItemContent , EcmascriptChunkPlaceable ,
25
+ EcmascriptChunkingContext , EcmascriptExports ,
26
26
} ,
27
27
utils:: StringifyJs ,
28
28
} ,
@@ -239,12 +239,13 @@ impl ChunkItem for WithClientChunksChunkItem {
239
239
}
240
240
241
241
#[ turbo_tasks:: function]
242
- fn as_chunk ( & self , availability_info : Value < AvailabilityInfo > ) -> Vc < Box < dyn Chunk > > {
243
- Vc :: upcast ( EcmascriptChunk :: new (
244
- Vc :: upcast ( self . context . with_layer ( "rsc" . to_string ( ) ) ) ,
245
- Vc :: upcast ( self . inner ) ,
246
- availability_info,
247
- ) )
242
+ fn ty ( & self ) -> Vc < Box < dyn ChunkType > > {
243
+ Vc :: upcast ( Vc :: < EcmascriptChunkType > :: default ( ) )
244
+ }
245
+
246
+ #[ turbo_tasks:: function]
247
+ fn module ( & self ) -> Vc < Box < dyn Module > > {
248
+ Vc :: upcast ( self . inner )
248
249
}
249
250
}
250
251
0 commit comments