TypeScript compiling as a single JS file

typescript

Solution

You have to use command line arguments of compiler

`--outFile FILE` Concatenate and emit output to single file

example

 tsc --outFile modules.js main.ts app.ts

Problem

I have a test project on TypeScript, code can found here. When I'm creating new project with VS2012, an `app.ts` file is created. When I'm changing it's content as shown by the link and adding new module called `GameModule`, I'm getting compile error. When I'm deleting `app.ts` and creating `Main.ts` instead, everything compiling fine, but there is a problem - only `Main.ts` is compiled to `Main.js`, and `GameModule.ts` stays uncompiled. How can I make compiler to merge all the code in one JS?

Original source

Related problems