TypeScript compile all ts files as a single JavaScript file in WebStorm 7
javascript, typescript, webstorm
Solution
You can specify --out option in Typescript File watcher arguments, and, if 'track only root files' option is on, all ts files will be merged into a main js file (that imports them all directly or via references chain) on modifying any of them
Problem
I have a lot of .ts files in my project. WebStorm build each .ts file as a js file. But I dont want that. I have an app.ts file and all other .ts files will be build in that app.ts file. How can I do that in WebStorm 7? There is a solution in CLI mode but how can i implement it in WebStorm? ``` tsc --out app.js main.ts app.ts a.ts b.ts ``` Or is there a better way to do this? ANSWER Just added this line at Arguments section in Edit Watcher ``` --sourcemap $FileName$ --out your-main.js ```