We've implemented TypeScript in our Visual Studio 2015 (Update 2) setup for a non-ASP.Net project consisting of pure HTML and JavaScript. In order to disable the 'allowUnreachableCode' option, we made adjustments in the tsconfig file. It's common practice to include an early 'return' statement for debugging purposes. However, after turning off the unreachable code warning by setting the 'allowUnreachableCode' compiler option, we encountered a 'VSTSC' error during compilation: JsErrorScriptException (0x30001).
TSCONFIG
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"sourceMap": true,
"watch": true,
"allowUnreachableCode": true
}
}
CODE
let router = new Router();
router.start()
return;
... additional code