Convert string to lowerCase with .smallCase()

.smallCase();


Description:Convert string to lowercase. If value is not of type string, the value will be cast as a "String" before converted to lowerCase value.


Example:

<!doctype html>
    <html lang="en">
    <head>
      <meta charset="utf-8">
      <title>smallCase demo</title>
      <script src="http://code.bitsycode.com/bitsycode-latest.min.js"></script>
    </head>
    <body>
      
      <div class="content-container">THIS TEXT WILL BE SET TO smallCase</div><br />
      <button onclick="convertLower()">Convert to LowerCase</button>
      
      <script type="text/javascript">
         
         function convertLower() {
            var content = bitsyCode(".content-container").text();
            var converted = bitsyCode.smallCase(content);
            bitsyCode(".content-container").text(converted);
         }
         
      </script>
     
    </body>
    </html>

Preview:

THIS TEXT WILL BE SET TO smallCase

  • Usage

    • How to use:

      Convert string to LowerCase.

    • USAGE:

      bitsyCode.smallCase("content");
  • Options

    • What options are there:

      There are no options for this method.

  • Returns

    • Returns: A string converted to lowercase will be returned.
Share