What is class and how to use class in Javascript?
A class is a type of function in Javascript. It can be declared with the class keyword. We can use these function expression syntax to initialize a function and class expression syntax to initialize a class in Javascript.
BY Best Interview Question ON 08 Dec 2020
Example
function PrintString(name1, name2, name3) {
alert(name1 + name2 + name3);
}
const result = new PrintString(1, 2, 3);