Short intro about string functions in JavaScript

Learn about available JavaScript string functions. Image taken fromΒ unsplash String Properties 1.length var str = “Jagathish”;str.length; //9 –> returns the length of the string Functions toUpperCase() –> returns the new string in uppercase format of source string var str = “Jagathish”; var str2 = str.toUpperCase(); console.log(str);//Jagathish console.log(str2);//JAGATHISH 2.toLowerCase() –> returns the new string in lowercase …

Difference between String primitives and String object.

Learn about, in what way the string primitive and string objects are different in javascript. We can create string in three ways, 1. var a = “first way”; // we can also use single quotes 2. var b = String(“second way”); 3. var c = new String(“third way”); // also we can create using 4. …

Design a site like this with WordPress.com
Get started