Skip to content

Commit 0dea7f9

Browse files
authored
fix(runtime-core): show hydration mismatch details for non-rectified mismatches too when __PROD_HYDRATION_MISMATCH_DETAILS__ is set (#10599)
1 parent 5aaa758 commit 0dea7f9

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,4 @@ TODOs.md
1010
.eslintcache
1111
dts-build/packages
1212
*.tsbuildinfo
13+
*.tgz

packages/runtime-core/src/hydration.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -443,14 +443,15 @@ export function createHydrationFunctions(
443443
if (props) {
444444
if (
445445
__DEV__ ||
446+
__FEATURE_PROD_HYDRATION_MISMATCH_DETAILS__ ||
446447
forcePatch ||
447448
!optimized ||
448449
patchFlag & (PatchFlags.FULL_PROPS | PatchFlags.NEED_HYDRATION)
449450
) {
450451
for (const key in props) {
451452
// check hydration mismatch
452453
if (
453-
__DEV__ &&
454+
(__DEV__ || __FEATURE_PROD_HYDRATION_MISMATCH_DETAILS__) &&
454455
propHasMismatch(el, key, props[key], vnode, parentComponent)
455456
) {
456457
hasMismatch = true

0 commit comments

Comments
 (0)