Answer Posted / hrpatelsoft@gmail.com
An enum is a type restricting variables to one value from a predefined set of constants. JavaScript has no enums but typescript provides built-in enum support.
enum Color {
RED, GREEN, BLUE
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How can I learn coding fast?
How to convert a string to a number using javascript?
If we want to return the character from a specific index which method is used?
why can't we call a static method from a non-static method
How do I add a javascript event handler to an html page element?
what is the difference between let, var, and const?
What is a function in javascript and how does it work?
How to call a function in every x seconds in javascript?
Which built-in method returns the length of the string?
can wwe trace a java program (class)
How to manage exception handling in javascript?
Please write the Code of simple javascript calculator withot eval() function
Does spread operator deep copy?
Does javascript support foreach loop?
What is js injection?