title: Is it necessary to call `unmountComponentAtNode` if the component's container is removed?
body: <p>I render a React component <code>SettingsTab</code> within a wrapper called <code>TeamView</code>. Its API looks something like</p>
  
  <pre><code>class TeamView {
    constructor() {
      this.el = document.createElement('div');
    }
  
    render() {
      ReactDOM.render(&lt;SettingsTab/&gt;, this.el);
      return this;
    }
  
    remove() {
      this.el.remove(); 
    }
  }
  </code></pre>
  
  <p>used something like</p>
  
  <pre><code>// to present the team view
  const teamView = new TeamView();
  document.body.appendChild(teamView.render().el);
  
  // to remove the team view
  teamView.remove();
  </code></pre>
  
  <p>And what I'm wondering is, <strong>should <code>TeamView#remove</code> call <code>ReactDOM. unmountComponentAtNode(this.el)</code> before calling <code>this.el.remove()</code></strong>?</p>
  
  <p>The examples I can find around the web make it seem like <code>unmountComponentAtNode</code> only needs to be called if the container is going to remain in the DOM; and the new <a href="https://facebook.github.io/react/docs/portals.html#event-bubbling-through-portals" rel="noreferrer">portals example</a> just removes the container, without calling <code>unmountComponentAtNode</code>.</p>
  
  <p>But, I'm not sure if that's special because it's using a portal, and <a href="https://facebook.github.io/react/blog/2015/10/01/react-render-and-top-level-api.html" rel="noreferrer">this post</a> makes it kind of seem like it's always good practice to call <code>unmountComponentAtNode</code>.</p>