title: How to add vanilla .js to a custom Vue component
body: <p>I'm trying to add a simple <a href="https://chmln.github.io/flatpickr" rel="nofollow noreferrer">date-picker</a> to a custom vue component. I'm not using webpack so I want to avoid ready made <code>.vue</code> components and I rather understand how to add simple javascript to vue.</p>
  <p>I'm following <a href="https://v2.vuejs.org/v2/examples/select2.html" rel="nofollow noreferrer">this official vue tutorial</a></p>
  <p>I've also seen <a href="https://codepen.io/apertureless/pen/vxWbqB?editors=1010" rel="nofollow noreferrer">this codepen</a> but I can't manage to make the date picker appear.</p>
  <p>This is my <a href="https://jsfiddle.net/cosbgn/j4v3z6nk/2/" rel="nofollow noreferrer">jsfiddle</a>:</p>
  <p>Html:</p>
  <pre><code>&lt;div class=&quot;app&quot;&gt;
    &lt;datepicker id='date-elem'&gt;&lt;/datepicker&gt;
  &lt;/div&gt;
  </code></pre>
  <p>app.js:</p>
  <pre><code>Vue.component('date-picker', {
    extends: Flatpickr,
    mounted () {
      this.Flatpickr(date-elem, {})}
  })
  </code></pre>
  <p>How can I easily integrate vanilla js in a Vue component without the need of .vue files, webpack etc?</p>