How to create the first Node Js project in TypeScript - Hello World.

Опубликовано: 02 Март 2026
на канале: TypeScript Insights
327
3

Hello World Steps:

Install Node.js from https://nodejs.org/

Install TypeScript 4.9+ using Node Package Manager command (https://www.typescriptlang.org/downlo...

npm install -g typescript
Install VSCode from https://code.visualstudio.com/Download

Read: https://bobbyhadz.com/blog/typescript...

Read: https://www.typescripttutorial.net/ty...

Generate tsconfig.json by giving this command:

tsc --init
If you want to run TypeScript tsc command in Windows Powershell:

Open Powershell in Adminstrator mode

Run command:

Set-ExecutionPolicy RemoteSigned
Policy updated and now you can run tsc command in powershell.

For more Details Check this out

Make it a Node.js project by giving the following command:

npm init -y
Install types for Node.js

npm i @types/node -D


Create file index.ts


tsc
Run transpiled javascript by running the following command:

node index.js