I have a parent that has two children.
ReactDOM.render(
<div>
<SaveCart />
<ImportCart carts={response.items || []}/>
</div>,
newContainer
);
SaveCart is only a component and renders only a Button which handles a prompt modal asks a name and save it via xhr request. http://kopy.io/rlzn0
ImportCart is another component that renders only a Button which handles a modal dialog of saved carts, and import them on a Shopping Cart functionality.http://kopy.io/mlK5w
The thing I want is if my saved carts are empty, when a cart is saved via SaveCart component I want to update the carts prop or state in ImportCart.