Is it possible to set a “compiler” option to compile more TypeScript files in one project to one JavaScript file?
The only solution I can find is passing multiple files to the “tsc” manually by hand, but I’d like to use the features of the IDE Visual Studio 2012.
Is it possible to set a compiler option to compile more TypeScript files in
Share
I am using bundling to do this in ASP.NET. You can use bundling with MVC or Web Forms.
If you are using Web Essentials, you will already be getting both a
.jsand a.min.jsand bundling is clever enough to use the.jsfiles at debug time and the minified versions in production – so you can debug easily but get smaller files in live.You can read all about Bundling and Minification on the ASP.NET site.
However, if you want TypeScript to bundle the file (it won’t minify it) you just need to use the following flag:
TypeScript will walk the dependencies and sort out the ordering for you so all you need to worry about is minifying the combined file.