Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(hydration): don't error if data-allow-mismatch provided for fragment #12505

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

dmitryuk
Copy link

@dmitryuk dmitryuk commented Dec 6, 2024

Fixes hydrateFragment method throws hydration mismatch error despite of data-allow-mismatch attribute exists in parent node.

fragment not enough children test was wrong since Hydration completed but contains mismatches. error was ignored in test environment and not checked at all

__TEST__ flag prevented to catch error for testing

added toHaveBeenErrored method that looks same as toHaveBeenWarned, but error level

@dmitryuk dmitryuk force-pushed the fix/hydration-error-allow-mismatch branch from 51f813c to ab617d5 Compare December 6, 2024 09:26
Copy link

github-actions bot commented Dec 9, 2024

Size Report

Bundles

File Size Gzip Brotli
runtime-dom.global.prod.js 100 kB (+9 B) 37.9 kB (-1 B) 34.2 kB (+22 B)
vue.global.prod.js 158 kB (+9 B) 57.8 kB (+1 B) 51.5 kB (+87 B)

Usages

Name Size Gzip Brotli
createApp (CAPI only) 46.6 kB 18.3 kB 16.7 kB
createApp 54.6 kB 21.3 kB 19.4 kB
createSSRApp 58.7 kB (+9 B) 23 kB (+4 B) 20.9 kB (-2 B)
defineCustomElement 59.4 kB 22.8 kB 20.8 kB
overall 68.4 kB 26.4 kB 24 kB

Copy link

pkg-pr-new bot commented Dec 9, 2024

Open in Stackblitz

@vue/compiler-core

npm i https://pkg.pr.new/@vue/compiler-core@12505

@vue/compiler-dom

npm i https://pkg.pr.new/@vue/compiler-dom@12505

@vue/compiler-ssr

npm i https://pkg.pr.new/@vue/compiler-ssr@12505

@vue/compiler-sfc

npm i https://pkg.pr.new/@vue/compiler-sfc@12505

@vue/reactivity

npm i https://pkg.pr.new/@vue/reactivity@12505

@vue/runtime-core

npm i https://pkg.pr.new/@vue/runtime-core@12505

@vue/runtime-dom

npm i https://pkg.pr.new/@vue/runtime-dom@12505

@vue/server-renderer

npm i https://pkg.pr.new/@vue/server-renderer@12505

@vue/shared

npm i https://pkg.pr.new/@vue/shared@12505

vue

npm i https://pkg.pr.new/vue@12505

@vue/compat

npm i https://pkg.pr.new/@vue/compat@12505

commit: 9e90946

@edison1105
Copy link
Member

Thanks for the PR. I've made some minor tweaks 9e90946
LGTM

@edison1105 edison1105 added ready to merge The PR is ready to be merged. 🍰 p2-nice-to-have Priority 2: this is not breaking anything but nice to have it addressed. labels Dec 9, 2024
@dmitryuk
Copy link
Author

dmitryuk commented Dec 9, 2024

@edison1105 thanks you so much for instant help!

I very hope the PR will be merged next release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🍰 p2-nice-to-have Priority 2: this is not breaking anything but nice to have it addressed. ready to merge The PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants