This is the Compielrs class initial project written in TypeScript. See http://www.labouseur.com/courses/compilers/ for details.
- Install npm, if you don't already have it
npm install -g typescript
to get the TypeScript Compiler
- Install npm, if you don't already have it
npm install -g gulp
to get the Gulp Task Runnernpm install -g gulp-tsc
to get the Gulp TypeScript plugin
Run gulp
at the command line in the root directory of this project.
Edit your TypeScript files in the source/scripts directory in your favorite editor. Visual Studio Code has some additional tools that make debugging, syntax highlighting, and more very easy.
IntelliJ looks like a nice option as well.
Gulp will automatically:
- Watch for changes in your source/scripts/ directory for changes to .ts files and run the TypeScript Compiler on it
- Watch for changes to your source/styles/ directory for changes to .css files and copy them to the dist/ folder
What's TypeScript? TypeScript is a language that allows you to write in a statically-typed language that outputs standard JavaScript.
Why should I use TypeScript? This will be especially helpful for an OS or a Compiler that may need to run in the browser as you will have all of the great benefits of scope and type checking built right into your language.
Where can I get more info on TypeScript Right this way!
Where can I get more info on Gulp? Right this way!