by jefftchan · 12y ago · 0 comments
[1] https://github.com/facebook/react/blob/master/src/addons/tra... [2] https://github.com/facebook/react/issues/1950
<Transition current={this.state.mode}>
<TransitionItem name="map">
<Map .../>
</TransitionItem>
<TransitionItem name="list">
<List .../>
</TransitionItem>
</Transition>
By making the possible children explicit, you can preserve them in the virtual DOM as long as is needed. The actual child (Map and List) would be mounted/unmounted only as needed.