Closed mayerraphael closed 5 months ago
@mayerraphael thanks for raising this issue and helping us make Stencil better.
tested with keydown
Can you please describe how you did trigger the event? If I change the eventName
to click
, everything works fine when clicking on it.
Actually after some more testing, I am able to reproduce this issue and can investigate/work on a solution.
A bug fix has been proposed in #5877 and a dev release (4.19.1-dev.1719875079.a06f64c
) confirmed that it fixes the double rendering in the provided reproduction case.
Prerequisites
Stencil Version
4.19.0
Current Behavior
If a component has a
@Listen()
function (tested with keydown) Stencil hydrate crashes and does not serialize the component.Culprit is the
hydrateComponent
method:Expected Behavior
For components to correctly serialize with
@Listen()
methods.System Info
No response
Steps to Reproduce
See repository.
Code Reproduction URL
https://github.com/mayerraphael/stencil-dsd-ssr-playground
Additional Information
The
my-whatever-component
has an@Listen()
method.Affects both
serializeShadowRoot
true and false.