title: Javascript / Add class to element with interval
body: <p>Javascript isn't my forte, so I'm looking for help : How would you write a function which add a Class to 3 elements with interval ?</p>
  
  <pre><code> &lt;ul&gt;
     &lt;li class="panel"&gt;Item 1&lt;/li&gt;
     &lt;li class="panel"&gt;Item 2&lt;/li&gt;
     &lt;li class="panel"&gt;Item 3&lt;/li&gt;
   &lt;/ul&gt;
  </code></pre>
  
  <p>The idea is to add an <code>.--active</code> class on the 1st item when document is ready and remove it after 2sec to add it to the 2nd item and so on.</p>