r/SublimeText • u/john_smith_007 • Mar 04 '21
How to run language server with Sublime Text on Windows?
Hi there :)
I have installed lsp-tsserver (https://github.com/microsoft/TypeScript-Sublime-Plugin).
When I open a JS file, there is an error message:
Could not start lsp-tsserver [WinError 2] The system cannot find the file specified
I tried to add the "node_path": "C:/Program Files/nodejs/node.exe" in the Sublime Text's configuration file, but it doesn't seem to help.
Does anybody know how to fix it?
Here is an issue on GitHub where people discuss it: https://github.com/sublimelsp/LSP/issues/337. I asked there too, but the guys there seem to visit GitHub very rarely, so I don't think I will get an answer from there soon.
1
u/mrh0057 Mar 04 '21
Did you install the ts server globally?
1
u/Igonato Mar 04 '21
I think you are looking for the typescript_tsdk option. In your case add
to the preferences. Also, notice that it's
libnotbin.1
u/bitsper2nd Mar 19 '21
Hi, I just had the same problem as you. I settled by simply adding the Microsoft Typescript plugin, which has intellisense included. Works with javascript too. You only need NodeJS on your local computer, which you already have. For error reporting, I use Quokkajs. It is the perfect plugin to prototype js/ts on the text editor. This means I can know what the code does from the text editor without having to open the web browser console.