title: How to render Redux Container in ReactDOM.render method
body: <p>For example:</p>
  
  <p>In Link.js</p>
  
  <pre><code>class Link extends React.Component {
     ... 
  }
  export default Link
  </code></pre>
  
  <p>In LinkContainer.js</p>
  
  <pre><code>import { connect } from 'react-redux'
  import Link from './Link'
  
  
  const mapStateToProps = (state, ownProps) =&gt; {
    return {
      data: state.data
    }
  }
  
  
  const LinkContainer = connect(
    mapStateToProps
  )(Link)
  
  export default LinkContainer
  </code></pre>
  
  <p>In App.js. I have a onClick method to render Link on the fly.</p>
  
  <pre><code>class App extends React.Component {
     ...
     onClick() {
        ReactDOM.render(&lt;LinkContainer /&gt;,document.getElementById('link1')) //It doesn't work
       // ReactDOM.render(&lt;Link /&gt;,document.getElementById('link1')) //It works
  
     }
  }
  </code></pre>
  
  <p>When i render container the error happened</p>
  
  <blockquote>
    <p>Uncaught Invariant Violation: Could not find "store" in either the context or props of "Connect(Link)". Either wrap the root component in a , or explicitly pass "store" as a prop to "Connect(Link)</p>
  </blockquote>