title: Use react-redux sub-apps?
body: <p>I have a general architectural react-redux question whether to use sub-app approach or not.</p>
  
  <p>At the moment we're developing a generic list/detail view.
  For the <em>list-view</em>, we retrieve the data with redux-saga and save them to the redux store and connect them to the list component. On paging/search we trigger an action that refreshes those data.
  A requirement is, that the <em>detail-view</em> can contain <em>list-views</em> of related records (<em>sub-list</em>).
  The root <em>list-view</em> and the <em>sub-list</em> are visually almost the same, except maybe a search form should not be visible by default and and actions should work differently (only retrieve related data, row-click should not show detail in sub-list...)</p>
  
  <p>To solve this I can think of two solutions:</p>
  
  <p><strong>-1- Reuse Components, share store</strong></p>
  
  <p>We can reuse the <em>list-view</em> container. With a dynamic amount of <em>sub-lists</em> we have to store the data with an id in the store. On paging etc. we have to replace the correct dataset. Garbage Collection has to be handled manually.
  <a href="https://i.stack.imgur.com/UD1L6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/UD1L6.png" alt="Reuse"></a></p>
  
  <p><strong>-2- Sub-App Approach</strong></p>
  
  <p>As described here: <a href="http://redux.js.org/docs/recipes/IsolatingSubapps.html" rel="nofollow noreferrer">Isolated Subapps</a> We could create an isolated component of the detail/list-view. If we want to have a subgrid we simply include this component. This would be the same as we use for the root<em>list-view</em>.
  <a href="https://i.stack.imgur.com/TrdrG.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/TrdrG.png" alt="Sub-app"></a></p>
  
  <p><strong>Pro/Cons</strong></p>
  
  <p>For the subapp I see advantage in autonomy. The data could be kept in a separate store and we don't have to implement something "id-based" in the store. We can destroy the subapp and the store is removed as well. 
  On the downside, some data is being retrieved on root level und since we don't want the sub-app to do the same REST call to get those, we need to find a way to send these informations to the sub-app. And a row-click probably has an effect on the root view (redirect)
  So the sub-app needs to send data and get data of the root element and is therefore not as isolated as I wish.</p>
  
  <p>Does anyone made some valuable experience with any approach? Any feedback would be greatly appreciated! </p>