mattn / vim-lsp-settings

Auto configurations for Language Server for vim-lsp
MIT License
1.26k stars 225 forks source link

`:LspStatus` returns `typescript-language-server: not running` #743

Open OurCodeBase opened 2 months ago

OurCodeBase commented 2 months ago

Why :LspStatus returns typescript-language-server: not running ? Please show me how to run typescript-language-server in neovim.

$ vi helloworld.js
:PlugInstall
:LspInstallServer
:LspStatus
typescript-language-server: not running

I have read closed issue #547 and included these lines to init.vim file:-

let g:lsp_diagnostics_echo_cursor = 1
let g:lsp_settings = {
\ 'efm-langserver': {
\   'disabled': v:false
\ },
\ }

autocmd BufWritePre *.js,*.jsx call execute('LspDocumentFormatSync --server=efm-langserver')

But the error still appears the same...

mattn commented 2 months ago

Question:

OurCodeBase commented 2 months ago

No, I'm using tsserver on a standalone script.js file. Expecting auto-completions on atleast console.log().

subeenregmi commented 1 week ago

Creating a folder node_modules in the same directory of my script.js file seemed to make the language server work for me.