Creative

How to convert date to string in TypeScript

In this blog we can see how to convert date to string using type script . The Date object is the basis of TypeScript’s date and time functionality. If no arguments are passed to its function Object() { [native code] }, it will contain the user’s computer’s current date an...

Creative

Top10 interview questions in typescript

In this blog we will see some of the type script interview Questions in type script. 1. What is undefined in TypeScript? A variable is given the value of undefined when it is declared but not initialised. On its own, it is not particularly beneficial. If a variable has been declared but no...

Creative

Try Catch Statement in TypeScript

In this blog we will see what is try catch statement in Typescript. Try catch Statement in TypeScript :  The try catch statement in TypeScript allows you to handle some or all of the errors that may occur in your application. These errors are frequently referred to as exceptions. A try-ca...

Creative

What is Ternary Conditional Operator in Type Script

In this blog we can see what is ternary conditional operator in TypeScript.Ternary conditional operator : The Typescript conditional operator is a Ternary Operator with three operands. The first operand is an evaluation condition. It is followed by a question mark (? ), and finally by an e...

Creative

How to use Switch() Statement in TypeScript

Introduction: In this blog we can see how to use switch() statement in TypeScript . A switch statement is a useful tool for expressing a certain kind of condition. If just one expression is evaluated for equality with a variety of values, it can be used in place of an if statement with num...

Creative

How to use if else statement in type script

In this blog we will discuss about how to use if else condition in TypeScript . An if-else statement allows you to control the execution of statements based on conditional expression results. An if statement may contain multiple else and if clauses, as well as one else clause at the end. I...

Creative

How to sort An Array in TypeScript

In this type script tutorial we can see how to sort an array of an object uing type script. The array sort() function is used to sort an array. With the specified optional comparison function. Javascript will sort the array object if it is not provided by converting values to strings and c...

Creative

Top 10 TypeScript Interview Questions and answers

    In this Blog we will discuss about top 10 interview Questions in Typescript. 1. What is TypeScript and how does it differ from JavaScript? TypeScript is a subset of JavaScript that can be translated into standard JavaScript. From a conceptual standpoint, TypeScript and JavaSc...

Creative

How to use Function type in TypeScript?

In this we can define that functions in Typescript  . Defining a Function : A function definition specifies what and how a specific task would be done. Before using a function, it must be defined. Functions are defined using the function keyword. Syntax :  function function_name() {// fu...