0

Convert TypeScript to JavaScript

This post demonstrate the basic process of converting TypeScript codes to JavaScript.

Stuff Used

  • Windows 10
  • TypeScript 3.0.3
    • To be installed (see instructions below)
  • NodeJS 8.11.3
    • Must be installed
  • npm 5.6.0
    • Must be installed
  • Visual Studio Code 1.24.1
    • Alternatively, we can use any text file editor

Verify Versions

Verify npm version

Verify NodeJS version

Install TypeScript

We need to install TypeScript using the installed NodeJS and npm.

Verify TypeScript version.

Our TypeScript Codes

To convert these codes, perform the following operation on the command line window.  A file HelloEarth.js is then generated.

Running HelloEarth.js

Karl San Gabriel

Karl San Gabriel

Java and Enterprise Technologies Expert