Ts – Enum

Enums are one of the few features TypeScript has which is not a type-level extension of JavaScript. Enums allow a developer to define a set of named constants

enum Direction {
  UP = 1,
  DOWN,
  LEFT,
  RIGHT,
}
enum Role {
   ADMIN:"Admin",
   SUPERADMIN:"Super Admin",
}
enum Role {
    NORMALUSER:"Normal User"
}
console.log(Role.ADMIN)


console.log(Role.ADMIN)  // Admin
console.log(Role.NORMALUSER) // Normal User

Tuple

let person:[number,boolean, ...string]=[20, true, 'ajay']