In my development process using Visual Studio to work on my TypeScript project, I have encountered an issue with the build process. I have a build.ts file that links to all of my other TS files and compiles them into one app.js file along with an associated map file.
Although the build process appears to be successful, if the js file already exists, it is not updated when I rebuild. Deleting the js file allows it to be recreated without any issues, indicating that the problem lies with an existing js file rather than its write permissions.
To work around this issue, I added a call to tsc in my prebuild event command line, which has resolved the update problem by forcing a recompilation. However, this solution feels less than ideal as it requires duplicate configuration settings and may lead to compatibility issues like those experienced when upgrading from TypeScript 1.4 to 1.5.
While I can manage with the workaround in place, it highlights a significant flaw in Visual Studio's handling of compiled output updates, making it necessary for users to intervene manually during the build process.