Commit 6f2fa9c
committed
minor #2699 key is more reliable with child components (weaverryan)
This PR was merged into the 2.x branch.
Discussion
----------
key is more reliable with child components
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no <!-- please update src/**/CHANGELOG.md files -->
| Docs? | yes
| Issues | Fix #1643
| License | MIT
I couldn't track down why, but for child components, `key` is more reliable. When `id` is used and a child requires re-rendering (because input props changed), the dummy element returned by https://github.com/symfony/ux/blob/2.x/src/LiveComponent/src/EventListener/InterceptChildComponentRenderSubscriber.php will not have an `id`, but with `key` it will. Smells like a bug, but `key` works
Commits
-------
304acf8 key is more reliable with child components1 file changed
+3
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3202 | 3202 | | |
3203 | 3203 | | |
3204 | 3204 | | |
3205 | | - | |
| 3205 | + | |
3206 | 3206 | | |
3207 | 3207 | | |
3208 | 3208 | | |
3209 | 3209 | | |
3210 | 3210 | | |
3211 | 3211 | | |
3212 | | - | |
| 3212 | + | |
3213 | 3213 | | |
3214 | 3214 | | |
3215 | 3215 | | |
| |||
3224 | 3224 | | |
3225 | 3225 | | |
3226 | 3226 | | |
3227 | | - | |
3228 | | - | |
3229 | | - | |
3230 | | - | |
3231 | 3227 | | |
3232 | 3228 | | |
3233 | 3229 | | |
| |||
3242 | 3238 | | |
3243 | 3239 | | |
3244 | 3240 | | |
3245 | | - | |
3246 | | - | |
3247 | | - | |
| 3241 | + | |
3248 | 3242 | | |
3249 | 3243 | | |
3250 | 3244 | | |
| |||
0 commit comments