Posts

Showing posts from 2024

Typescript configuration file

Even if your program contains error typescript converted ts file to java script. we don't want this behavior if there is any error in typescript don't want its JavaScript file  for that we need typescript configuration file tsc --init open config file and uncomment "noEmit": true,    or you can use below command tsc --noEmitOnError   test.ts

TypeScript-2 : First Example

 extension of type script  file is .ts example abc.ts xyz.ts pqr.ts test.ts let x = 10 log.console(x) command to run file :  tsc test.ts after execution created new file - test.js run :-                               node test.js file is not compile its trans file : one human level language to other human level language

TypeScript- 1: Installation

                                                       how to install typescript: to install typescript first install node in your computer and then below command. npm install -g typescript -g stand for global. Here have install typescript globally , it means I can access anywhere in my computer. Check typescript properly installed or not tsc --v                                                                    Steps to install node JS : type "node js " in google  click on first link you will redirected to https://nodejs.org/en download node js and install in your computer  check node properly installed or not by using "node -v"  command