Closed gioboa closed 6 months ago
Thanks for the feedback, @gioboa. I have been busy, I'll look into it this week.
@gioboa, in this case, this is the expected behaviour. Each Router component has its context and its parameters. If you notice, the Route1 component belongs to the two routers in the example, which is why the useVisibleTask$
is executed twice. Executing one, would overwrite the other Router component's behaviour.
Given that, tell me if you would expect a different behaviour and why.
I see, in the meantime I solved my problem with a ternary { route === 'A' ? <CmpA /> : <CmpB /> }
I will give another try to the lib. Thanks for your work 👍
Which component is affected?
Qwik Runtime
Describe the bug
I cloned your starter
git clone https://github.com/dannyfranca/qwik-router.git
and I addeduseVisibleTask$
in the Route1 component hereand the
useVisibleTask$
called twiceReproduction
-
Steps to reproduce
-
Additional Information
to avoid this problem I can create my own useVisibleTask$ wrapper