title: Move components in dom around without 'destroying component'
body: <p>I'd like to find a way to move my component around in the DOM without destroying the component. I want the component to stay initialized. Here's what I have so far:</p>
  <pre><code>&lt;div *ngIf=&quot;conditionIsTrue&quot;&gt;
    &lt;ng-container [ngTemplateOutlet]=&quot;myComponentContainer&quot;&gt;&lt;/ng-container&gt;
  &lt;/div&gt;
  
  &lt;div *ngIf=&quot;conditionIsFalse&quot;&gt;
    &lt;ng-container [ngTemplateOutlet]=&quot;myComponentContainer&quot;&gt;&lt;/ng-container&gt;
  &lt;/div&gt;
  
  &lt;ng-template #myComponentContainer&gt;
    &lt;my-component&gt;
    &lt;/my-component&gt;
  &lt;/ng-template&gt;
  </code></pre>
  <p>My set up works, the component gets injected into different divs based on the condition, but because of this setup (ngIfs), the component gets destroyed and reinitialized. I can't have this happen. What can I do here?</p>