Post

How to Install Typescript?

First, we need to install Node.js to work with TypeScript.

Node.js provides an environment to execute JavaScript outside the browser. Install the latest stable version of Node.js. After installing Node.js, you’ll have NPM (Node Package Manager), which helps you install third-party libraries.

Open the command prompt and type the following command to check if Node.js is installed:

node --version

This should display the installed version (e.g., v12.16.3).

Next, install TypeScript globally using the following command:

npm install -g typescript

The -g flag indicates a global installation.

After successful installation, verify TypeScript by running:

tsc --version

This should display the installed version (e.g., Version 3.9.2).

Now you can start working with TypeScript using your favorite editors like Visual Studio Code, Sublime Text, Atom, etc.

For more information, explore the basic concepts of TypeScript.

Feel free to reach out if you have any further questions! 😊

Enjoy this blog? Buy Me A Coffee 💖 Sponsor on GitHub
This post is licensed under CC BY 4.0 by the author.

Comments powered by Disqus.