I have three folders in my visual studio 2017 solution.
- project-a
- project-b
- lib
Each of these folders have a tsconfig.json file. I have setup these tsconfig files according to the typescript docs and to my older SO answer here: https://stackoverflow.com/a/54772741/681803
In visual studio code, I simply change my build script in my package.json from tsc
to tsc --build
. That will build all project listed in my project references list of my tsconfig.
However, I can't find out now how to do the same with visual studio 2017 (for another project)
When I build visual studio project-a (or project-b), it fails to build as the compiler can't find the references of the lib project (not build yet).
When I first manually run tsc
in the common folder before building project-a or project-b, it does compile because the output folder now already contains the typescript definition files of the lib project which are needed for project-a and project-b.
How to setup visual studio 2017 to work with typescript project references?