title: How to render polymorphic list in vue.js?
body: <p>Consider:</p>
  
  <pre><code>class X {}
  class B extends X {}
  class C extends X {}
  </code></pre>
  
  <p>In a component, I have an array of X:</p>
  
  <pre><code>&lt;template&gt;
      &lt;ul&gt;
          &lt;li v-for="item in items"&gt;
              &lt;a-view v-if="item.constructor.name === 'A'"&gt;&lt;/a-view&gt;
              &lt;b-view v-if="item.constructor.name === 'B'"&gt;&lt;/b-view&gt;
          &lt;/li&gt;
      &lt;/ul&gt;
  &lt;/template&gt;
  
  export default {
      ...
  data() {
      return {
          items: [new A(), new B()]
      }
  }
  </code></pre>
  
  <p>This works, but is not elegant. The typecheck uses a string, where <code>item instanceof B</code> would be idiomatic es6 code. However, this does not work.</p>
  
  <p>What is the idiomatic way of rendering a polymorphic list in vue.js?</p>