TypeScript Interview Quiz
TypeScript Interview Questions What is TypeScript? Ans: It is open source, strongly typed, object oriented and compiled language developed by Microsoft. Why use TypeScript? Ans: There are following reasons : 1.) It is open source. 2.) TypeScript simplifies JavaScript code. 3.) It provides static type checking. 4.) It makes code easier to read and understand. 5.) TypeScript is nothing but JavaScript with some additional features. 6.) TypeScript will save developers time. 7.) TypeScript is a superset of ES3, ES5, and ES6. What are additional feature of TypeScript? Ans: 1.) Functions with optional parameters(optional parameter using ? ). Example : function echo(a : number, b : string, c : number?) : any{} 2.) Generics support. 3.) Modules support. 4.) Support inheritence property. 5.) enum type support. 6.) Interface support. TypeScript Compiler Ans: TSC convert the typescript file into javascript file. A JavaScript file cann