title: Browser's repainting is very slow when using jquery addClass and removeClass
body: <p>I have a page where I need to dynamically add or css classes. I have the following Jquery code in my page,</p>
  
  <pre><code>myElementsList.addClass('AClass').removeClass('BClass')
  </code></pre>
  
  <p>These css classes will change the color and background color of my elements. The problem is that this takes 2 or 3 seconds to repaint the browser.</p>
  
  <p>If i use css classes which does not eXist(or does not repaint the browser) then it will eecute very quickly.</p>
  
  <pre><code>myElementsList.addClass('NotEXistClassA').removeClass('NotEXistClassB')
  </code></pre>
  
  <p>Any suggestion will be welcome?</p>
  
  <p><strong>Edit</strong>:</p>
  
  <p>The way I solve this issue by changing the first 20 rows first and changing the remaining using a timer. I am also reseting this timer every time if the events raised again before the timer elapased.</p>
  
  <p>Any other suggestion is welcome.</p>