Answers for "typescript enum value to enum"

-1

typescript enum value to enum

enum Number {
  One,
  Two
}  

const numberOne: Number = "One" as Number;
const otherNumberOne: Number = Number.One;

const stringOne = Number[Number.One];
Posted by: Guest on August-31-2020

Code answers related to "TypeScript"

Browse Popular Code Answers by Language