fix passing strings as chunks (#22617)
Shu Ding committed
Oct 24, 2021 at 05:21 UTC
4298ddbc56a711cecfa672ec8ac60c94a02c9380
1 file changed
+6
-6
packages/react-dom/src/server/ReactDOMServerFormatConfig.js
+6
-6
@@ -471,7 +471,7 @@ function pushAttribute(
471
attributeSeparator,
472
attributeNameChunk,
473
attributeAssign,
474
- escapeTextForBrowser(value),
474
+ stringToChunk(escapeTextForBrowser(value)),
475
attributeEnd,
476
);
477
}
@@ -482,7 +482,7 @@ function pushAttribute(
482
attributeSeparator,
483
attributeNameChunk,
484
attributeAssign,
485
- escapeTextForBrowser(value),
485
+ stringToChunk(escapeTextForBrowser(value)),
486
attributeEnd,
487
);
488
}
@@ -493,7 +493,7 @@ function pushAttribute(
493
attributeSeparator,
494
attributeNameChunk,
495
attributeAssign,
496
- escapeTextForBrowser(value),
496
+ stringToChunk(escapeTextForBrowser(value)),
497
attributeEnd,
498
);
499
}
@@ -510,7 +510,7 @@ function pushAttribute(
510
attributeSeparator,
511
attributeNameChunk,
512
attributeAssign,
513
- escapeTextForBrowser(value),
513
+ stringToChunk(escapeTextForBrowser(value)),
514
attributeEnd,
515
);
516
}
@@ -532,7 +532,7 @@ function pushAttribute(
532
attributeSeparator,
533
stringToChunk(name),
534
attributeAssign,
535
- escapeTextForBrowser(value),
535
+ stringToChunk(escapeTextForBrowser(value)),
536
attributeEnd,
537
);
538
}
@@ -1146,7 +1146,7 @@ function pushStartCustomElement(
1146
attributeSeparator,
1147
stringToChunk(propKey),
1148
attributeAssign,
1149
- escapeTextForBrowser(propValue),
1149
+ stringToChunk(escapeTextForBrowser(propValue)),
1150
attributeEnd,
1151
);
1152
}