Quramy / tsuquyomi

A Vim plugin for TypeScript
http://www.vim.org/scripts/script.php?script_id=5151
1.39k stars 72 forks source link

It doesn't work when typescript is in node_modules #242

Open nvlled opened 6 years ago

nvlled commented 6 years ago

It doesn't work, e.g. the server doesn't start, when typescript is installed locally in the project. Removing typescript from the project's node_modules seems to fix this, although I am not sure exactly what the underlying cause is.

terite commented 6 years ago

I'm not a contributor to this project, but Tsuquyomi works for me with a local installation of typescript.

First I checked (in vim) which command was used to run tsserver

:echo tsuquyomi#config#tsscmd()
node ".../node_modules/typescript/bin/tsserver"

Then, I ran that command in my shell I am able to verify that tsserver starts without error

$ node ".../node_modules/typescript/bin/tsserver"
Content-Length: 76

{"seq":0,"type":"event","event":"typingsInstallerPid","body":{"pid":25079}}

Trying these commands may shed light on your issue, or at least help others to help you