Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error starting TypeScript language service in WebStorm 2018

I'm new to using WebStorm (v2018.2 on Windows 7) and trying to work with TypeScript. And I am getting following error, despite trying many combinations of the TypeScript configuration settings in WebStorm.

Error:Timeout on starting language service process

As a result, I'm unable to compile my .ts files within the IDE.

TypeScript is working fine from command line (i.e. successfully able to run tsc to compile .ts files).

I have thoroughly reviewed the WebStorm help documentation and other tutorials, but nowhere have I seen this error mentioned or how to resolve it.

like image 616
rwalker Avatar asked Oct 17 '18 20:10

rwalker


People also ask

How do I start a TypeScript project in WebStorm?

You don't need to do anything to use TypeScript with WebStorm. You can use it in any WebStorm project, including built-in project templates using JavaScript frameworks or existing projects. When you're ready to start writing TypeScript code, add a tsconfig. json file (TypeScript configuration file) to the project.

Does WebStorm support TypeScript?

With WebStorm, you can run and debug client-side TypeScript code and TypeScript code running in Node. js. Learn more from Running and debugging TypeScript.


1 Answers

I've encountered this error a few times myself, and in my case it seems to be a problem with the node interpreter WebStorm is trying to use.

Earlier this week something I had installed via mac's homebrew package manager added a new/broken build of node to my system as a dependency. When I started having issues with webstorm, I opened preferences > Languages & Frameworks > TypeScript and saw that the Node interpreter was set to /usr/local/bin/node instead of my usual nvm path. I opened a terminal and tried running the node executable it was pointed to, and found that it was throwing an error.

A lot of the specifics aren't really comparable to your situation since you're on Windows, but I think it's probably a similar root cause, a bad node executable is the only thing I've ever seen cause this error message.

like image 130
Kai Mollerud Avatar answered Oct 21 '22 14:10

Kai Mollerud