Creating OOP Class Objects in TypeScript
Let us have the following class User:
class User {
}
Let's create an object of this class:
let user = new User;
The type of the variable containing the class object must be the name of this class. Let's refine our code:
let user: User = new User;
Create two objects of class Employee.