@@ -432,9 +432,9 @@ describe('ReactDOMFizzServer', () => {
432
432
mergeOptions ( options , renderOptions ) ,
433
433
) ;
434
434
}
435
- function renderIntoDocumentAsPipeableStream ( jsx , fallback , options ) {
435
+ function renderDocumentAsPipeableStream ( jsx , fallback , options ) {
436
436
// Merge options with renderOptions, which may contain featureFlag specific behavior
437
- return ReactDOMFizzServer . renderIntoDocumentAsPipeableStream (
437
+ return ReactDOMFizzServer . renderDocumentAsPipeableStream (
438
438
jsx ,
439
439
fallback ,
440
440
mergeOptions ( options , renderOptions ) ,
@@ -6165,15 +6165,13 @@ describe('ReactDOMFizzServer', () => {
6165
6165
} ) ;
6166
6166
} ) ;
6167
6167
6168
- describe ( 'renderIntoDocument ' , ( ) => {
6168
+ describe ( 'renderDocument ' , ( ) => {
6169
6169
// @gate enableFloat && enableFizzIntoDocument
6170
6170
it ( 'can render arbitrary HTML into a Document' , async ( ) => {
6171
6171
let content = '' ;
6172
6172
writable . on ( 'data' , chunk => ( content += chunk ) ) ;
6173
6173
await act ( ( ) => {
6174
- const { pipe} = renderIntoDocumentAsPipeableStream (
6175
- < div id = "div" > foo</ div > ,
6176
- ) ;
6174
+ const { pipe} = renderDocumentAsPipeableStream ( < div id = "div" > foo</ div > ) ;
6177
6175
pipe ( writable ) ;
6178
6176
} ) ;
6179
6177
@@ -6196,7 +6194,7 @@ describe('ReactDOMFizzServer', () => {
6196
6194
let content = '' ;
6197
6195
writable . on ( 'data' , chunk => ( content += chunk ) ) ;
6198
6196
await act ( ( ) => {
6199
- const { pipe} = renderIntoDocumentAsPipeableStream (
6197
+ const { pipe} = renderDocumentAsPipeableStream (
6200
6198
< body id = "body" > foo</ body > ,
6201
6199
) ;
6202
6200
pipe ( writable ) ;
@@ -6220,7 +6218,7 @@ describe('ReactDOMFizzServer', () => {
6220
6218
writable . on ( 'data' , chunk => ( content += chunk ) ) ;
6221
6219
await expect ( async ( ) => {
6222
6220
await act ( ( ) => {
6223
- const { pipe} = renderIntoDocumentAsPipeableStream (
6221
+ const { pipe} = renderDocumentAsPipeableStream (
6224
6222
< html id = "html" >
6225
6223
< head id = "head" >
6226
6224
< title > a title</ title >
@@ -6231,7 +6229,7 @@ describe('ReactDOMFizzServer', () => {
6231
6229
pipe ( writable ) ;
6232
6230
} ) ;
6233
6231
} ) . toErrorDev (
6234
- 'A <head> tag was rendered with props when using `renderIntoDocument `. In this rendering mode React may emit the head tag early in some circumstances and therefore props on the <head> tag are not supported and may be missing in the rendered output for any particular render. In many cases props that are set on a <head> tag can be set on the <html> tag instead.' ,
6232
+ 'A <head> tag was rendered with props when using `renderDocument `. In this rendering mode React may emit the head tag early in some circumstances and therefore props on the <head> tag are not supported and may be missing in the rendered output for any particular render. In many cases props that are set on a <head> tag can be set on the <html> tag instead.' ,
6235
6233
) ;
6236
6234
6237
6235
expect ( content . slice ( 0 , 47 ) ) . toEqual (
@@ -6253,7 +6251,7 @@ describe('ReactDOMFizzServer', () => {
6253
6251
let content = '' ;
6254
6252
writable . on ( 'data' , chunk => ( content += chunk ) ) ;
6255
6253
await act ( ( ) => {
6256
- const { pipe} = renderIntoDocumentAsPipeableStream (
6254
+ const { pipe} = renderDocumentAsPipeableStream (
6257
6255
< html id = "html" >
6258
6256
< body id = "body" > foo</ body >
6259
6257
</ html > ,
@@ -6284,7 +6282,7 @@ describe('ReactDOMFizzServer', () => {
6284
6282
6285
6283
const errors = [ ] ;
6286
6284
await act ( ( ) => {
6287
- const { pipe} = renderIntoDocumentAsPipeableStream (
6285
+ const { pipe} = renderDocumentAsPipeableStream (
6288
6286
< html id = "html" >
6289
6287
< body id = "body" >
6290
6288
< Throw />
@@ -6332,7 +6330,7 @@ describe('ReactDOMFizzServer', () => {
6332
6330
6333
6331
const errors = [ ] ;
6334
6332
await act ( ( ) => {
6335
- const { pipe} = renderIntoDocumentAsPipeableStream (
6333
+ const { pipe} = renderDocumentAsPipeableStream (
6336
6334
< html id = "html" >
6337
6335
< BlockOn value = "foo" >
6338
6336
< body id = "body" >
@@ -6406,7 +6404,7 @@ describe('ReactDOMFizzServer', () => {
6406
6404
6407
6405
const errors = [ ] ;
6408
6406
await act ( ( ) => {
6409
- const { pipe} = renderIntoDocumentAsPipeableStream (
6407
+ const { pipe} = renderDocumentAsPipeableStream (
6410
6408
< html id = "html" >
6411
6409
< link rel = "stylesheet" href = "foo" precedence = "foo" />
6412
6410
< link rel = "stylesheet" href = "bar" precedence = "bar" />
@@ -6459,7 +6457,7 @@ describe('ReactDOMFizzServer', () => {
6459
6457
6460
6458
const errors = [ ] ;
6461
6459
await act ( ( ) => {
6462
- const { pipe} = renderIntoDocumentAsPipeableStream (
6460
+ const { pipe} = renderDocumentAsPipeableStream (
6463
6461
< html id = "html" >
6464
6462
< body id = "body" >
6465
6463
hello world
@@ -6505,7 +6503,7 @@ describe('ReactDOMFizzServer', () => {
6505
6503
6506
6504
const errors = [ ] ;
6507
6505
await act ( ( ) => {
6508
- const { pipe} = renderIntoDocumentAsPipeableStream (
6506
+ const { pipe} = renderDocumentAsPipeableStream (
6509
6507
< html id = "html" >
6510
6508
< body id = "body" >
6511
6509
< Throw />
@@ -6550,7 +6548,7 @@ describe('ReactDOMFizzServer', () => {
6550
6548
6551
6549
const errors = [ ] ;
6552
6550
await act ( ( ) => {
6553
- const { pipe} = renderIntoDocumentAsPipeableStream (
6551
+ const { pipe} = renderDocumentAsPipeableStream (
6554
6552
< html id = "html" >
6555
6553
< body id = "body" >
6556
6554
< BlockOn value = "error" >
@@ -6637,7 +6635,7 @@ describe('ReactDOMFizzServer', () => {
6637
6635
}
6638
6636
6639
6637
await act ( ( ) => {
6640
- const { pipe} = renderIntoDocumentAsPipeableStream (
6638
+ const { pipe} = renderDocumentAsPipeableStream (
6641
6639
< html id = "html" >
6642
6640
< head />
6643
6641
< body id = "body" >
@@ -6745,7 +6743,7 @@ describe('ReactDOMFizzServer', () => {
6745
6743
const errors = [ ] ;
6746
6744
try {
6747
6745
await act ( ( ) => {
6748
- const { pipe} = renderIntoDocumentAsPipeableStream (
6746
+ const { pipe} = renderDocumentAsPipeableStream (
6749
6747
< html id = "html" >
6750
6748
< head />
6751
6749
< link rel = "stylesheet" href = "foo" precedence = "foo" />
0 commit comments