Hi! Thanks a lot for creating rc-dock first of all. It's exactly what I was looking for!
I have one question about it though. I wrote an application component that looks like the following, which loads a few resources from a remote server and updates its states once loaded:
However, it looks to me that the state foo and bar are not propagated to <Foo /> and <Bar /> components I specified in the defaultLayout property.
Is this the expected behavior? If so, what's the correct way to propagate these properties to the components in the tabs? If not, what am I doing wrong? I basically want <Foo /> and/or <Bar /> to be re-rendered when foo and/or bar are updated, but <Foo /> shouldn't be re-rendered when only bar is updated for sure.
I just stumbled on the same problem. I believe that the easiest way around this limitation is to create a context in App that can then be consumed by Foo and Bar.
Hi! Thanks a lot for creating
rc-dock
first of all. It's exactly what I was looking for!I have one question about it though. I wrote an application component that looks like the following, which loads a few resources from a remote server and updates its states once loaded:
However, it looks to me that the state
foo
andbar
are not propagated to<Foo />
and<Bar />
components I specified in thedefaultLayout
property.Is this the expected behavior? If so, what's the correct way to propagate these properties to the components in the tabs? If not, what am I doing wrong? I basically want
<Foo />
and/or<Bar />
to be re-rendered whenfoo
and/orbar
are updated, but<Foo />
shouldn't be re-rendered when onlybar
is updated for sure.