JavaScript class
JavaScript class
The class statement is used to initialize a JavaScript class. It is a type of object template. Its constructor() method is called each time a class object is initialized. We can assign properties and methods in the constructor() method.
Syntax:-
Its syntax is:-
class className {
// methods and properties goes here
}