FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

TypeScriptSamples/js-and-ts at master · fhero/TypeScriptSamples · GitHub

Repository navigation

Latest commit

 

History

History
 
 
  1. TypeScriptSamples

js-and-ts

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

README.md

TypeScript Sample: Mixing TypeScript and JavaScript

Overview

A sample of how to use the allowJS option to use both JavaScript and TypeScript together. A simple text formatter is provided, written in JavaScript. This formatter is then used within a TypeScript class to format a computation.

To run this sample, you must have node installed. You can also use ts-node to run this directly without a compilation from TypeScript to JavaScript.

Running

$ tsc robot.ts`
$ node robot.js`

Back | FazBrowse Home | New Git URL