You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ts-node no longer working with TypeScript@2.7 #527
ts-node has a dependency on an old api called parseConfigFile that was removed in 1.7. In TypeScript 2.7 a new internal parseConfigFile was added with a different signature for a different purpose and it seems that due to the order in which ts-node looks for an API to parse a tsconfig.json file.
Example:
npm i ts-node
node
> require("ts-node/register.js");
TypeError: host.onUnRecoverableConfigFileDiagnostic is not a function
at Object.parseConfigFile (C:\dev\TypeScript\node_modules\typescript\lib\typescript.js:76999:18)
at readConfig (C:\dev\TypeScript\node_modules\ts-node\src\index.ts:471:25)
at Object.register (C:\dev\TypeScript\node_modules\ts-node\src\index.ts:205:18)
at Object.<anonymous> (C:\dev\TypeScript\node_modules\ts-node\register\index.js:1:16)
at Module._compile (module.js:569:30)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:503:32)
at tryModuleLoad (module.js:466:12)
at Function.Module._load (module.js:458:3)
at Module.require (module.js:513:17)
I would recommend changing the order of feature testing to push the check for parseConfigFile later in the readConfig function above and first test for newer functionality, or check against the ts.version property to ensure the correct version.
Activity
dragosbulugean commentedon Feb 9, 2018
TypeScript 2.7.1
ts-node 4.1.0
It is just stuck - doesn't do anything. Any clues as to why?
blakeembrey commentedon Feb 19, 2018
Thanks for your patience, I haven't had much time for OSS recently. I finally got to it with #536.