camel case function

 camelCaseFunction(data){

-            var arr = data.split(/[_]/);

-            var newStr = "";

-            for (var i = 0; i < arr.length; i++) {

-                newStr += arr[i].charAt(0).toUpperCase() + arr[i].slice(1)  +(',');

-            }

-            newStr = newStr.replace("-"," ")

-            return newStr;

         }

No comments:

Post a Comment

AI Tools

 Midjourney oter.ai aiva googlegemin dall-e copilot jasper copilot openaiplayground