@@ -326,7 +326,7 @@ function normalizeMarkupForTextOrAttribute(markup: mixed): string {
326
326
327
327
export function checkForUnmatchedText (
328
328
serverText : string ,
329
- clientText : string | number ,
329
+ clientText : string | number | bigint ,
330
330
isConcurrentMode : boolean ,
331
331
shouldWarnDev : boolean ,
332
332
) {
@@ -399,10 +399,12 @@ function setProp(
399
399
}
400
400
} else if ( typeof value === 'number' || typeof value === 'bigint' ) {
401
401
if ( __DEV__ ) {
402
+ // $FlowFixMe[unsafe-addition] Flow doesn't want us to use `+` operator with string and bigint
402
403
validateTextNesting ( '' + value , tag ) ;
403
404
}
404
405
const canSetTextContent = tag !== 'body' ;
405
406
if ( canSetTextContent ) {
407
+ // $FlowFixMe[unsafe-addition] Flow doesn't want us to use `+` operator with string and bigint
406
408
setTextContent ( domElement , '' + value ) ;
407
409
}
408
410
}
@@ -954,6 +956,7 @@ function setPropOnCustomElement(
954
956
if ( typeof value === 'string' ) {
955
957
setTextContent ( domElement , value ) ;
956
958
} else if ( typeof value === 'number' || typeof value === 'bigint' ) {
959
+ // $FlowFixMe[unsafe-addition] Flow doesn't want us to use `+` operator with string and bigint
957
960
setTextContent ( domElement , '' + value ) ;
958
961
}
959
962
break ;
@@ -2817,6 +2820,7 @@ export function diffHydratedProperties(
2817
2820
typeof children === 'number' ||
2818
2821
typeof children === 'bigint'
2819
2822
) {
2823
+ // $FlowFixMe[unsafe-addition] Flow doesn't want us to use `+` operator with string and bigint
2820
2824
if ( domElement . textContent !== '' + children ) {
2821
2825
if ( props . suppressHydrationWarning !== true ) {
2822
2826
checkForUnmatchedText (
0 commit comments