title: What's the recommended way of rendering a Blazor component dynamically?
body: <p>I am new to Blazor with basic Angular and Vue.js experience. I would like to render a list of polymorphic components:</p>
  
  <pre><code>&lt;ul&gt;
      @foreach (fruit of fruits) 
           &lt;li&gt;HOW DO I RENDER FRUIT HERE??? &lt;/li&gt; // render the fruit component
  &lt;/ul&gt;
  
  @code {
     // Each member in the list is a subtype of Fruit
     var fruits = List&lt;FruitComponent&gt; {
         new PearComponent(),
         new AppleComponent()'
         new BananaComponent(),
         new RasberryComponent()
  }
  </code></pre>
  
  <p>From what I've gleaned, there's a few ways to achieve this, each with their own disadvantages. An uncommon one suggests using an undocumented API call, which could become deprecated without notice, but it appears to be almost ideal. Another suggests emitting markup in the code which brings back the tedium of writing ASP.NET Server Controls. Finally, the most common suggests using conditional markup, while very simple, it couples the rendering code to the components it is rendering. </p>
  
  <p>Most of the documentation I've read could be stale and no longer pertinent. With the official release of Blazor, what's the recommended way to achieve this? </p>