how to nominate typescript compiler output
With Webstorm tracking changes in the source typescript files and using the bundled compiler, how can I have the compiled files be written written to another directory relative to the source file.
for example the source in modules/foo/bar.ts outputs to www/app/foo/bar.js
and modules/foo2/bar2.ts outputs to www/app/foo2/bar2.js
Please sign in to leave a comment.
Possible using tsconfig.json.
There are 2 possible solutions:
Then, enable 'Use tsconfig.json' in TypeScript compiler settings
I have two tsconfig.json files in the project and the tsconfig that I do not want to use is discovered by webstorm.
Can this situation be fixed?
WebStorm behaves as designed: it uses the tsconfig nearest to current file when transpiling your code.
If you don't like using multiple files, you can pass '--project' (or just '-p') command line option that specifies the path of a directory containing a tsconfig.json file to compiler. But you would need using 'set options manually' option then