Remove class from element with .removeClass()

.removeClass()


Description: Remove a class from element.


Example:

    <!doctype html>
    <html lang="en">
    <head>
      <meta charset="utf-8">
      <title>removeClass demo</title>
      <script src="http://code.bitsycode.com/bitsycode-latest.min.js"></script>
    </head>
    <body>
      
      <p class="yellow">Remove className <b>"yellow"</b> from this paragraph</p><br />
      
      <script>
         
         bitsyCode.ready(function(){
            
            bitsyCode('p').removeClass("yellow");
            
         })
         
      </script>
     
    </body>
    </html>

Preview:

<p>Remove className <b>"yellow"</b> from this paragraph</p>
  • Usage

    • How to use:

      Remove classes from elements using .removeClass()

    • USAGE:
      bitsyCode('element').removeClass("className");
  • Options

    • What options are there:

      There are no options for this method.

  • Returns

    • Returns: No return type

      This method does not need to return any type.

Share