title: How to initialize javascript at materialize 1.0
body: <p>I'm sorry for asking a dumb question. But my knowledge at JS is poor. I don't know how to initialize materialize component using JS, but with jquery it works well. For example i want to use Collapsible component.
  <a href="http://next.materializecss.com/collapsible.html" rel="nofollow noreferrer">http://next.materializecss.com/collapsible.html</a></p>
  
  <pre><code>&lt;ul class="collapsible"&gt;
  &lt;li&gt;
    &lt;div class="collapsible-header"&gt;&lt;i class="material-icons"&gt;filter_drama&lt;/i&gt;First&lt;/div&gt;
    &lt;div class="collapsible-body"&gt;&lt;span&gt;Lorem ipsum dolor sit amet.&lt;/span&gt;&lt;/div&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;div class="collapsible-header"&gt;&lt;i class="material-icons"&gt;place&lt;/i&gt;Second&lt;/div&gt;
    &lt;div class="collapsible-body"&gt;&lt;span&gt;Lorem ipsum dolor sit amet.&lt;/span&gt;&lt;/div&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;div class="collapsible-header"&gt;&lt;i class="material-icons"&gt;whatshot&lt;/i&gt;Third&lt;/div&gt;
    &lt;div class="collapsible-body"&gt;&lt;span&gt;Lorem ipsum dolor sit amet.&lt;/span&gt;&lt;/div&gt;
  &lt;/li&gt;
  &lt;/ul&gt;
  </code></pre>
  
  <p>And for initialization</p>
  
  <pre><code>// JS
  var elem = document.querySelector('.collapsible');
  var instance = new M.Collapsible(elem, options);
  
    // Or with jQuery
  
    $(document).ready(function(){
      $('.collapsible').collapsible();
    });
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/otst3.jpg" rel="nofollow noreferrer">My code</a></p>