Repository navigation
|
Hello everyone. I'm trying to setup the vue's language server on emacs using Here is my configuration: Here is the npm packages that are installed globally in my computer:
Now, starting the language server in a Is there any compability issues between vue-language-server and typescript package? I cant really guess anything from this output, suppose i miss something? |
Replies: 4 comments 2 replies
|
This does not look like a TypeScript 6 compatibility issue by itself. I tested the same package versions locally ( The exception instead means that the You can see exactly what that server resolves with: ROOT="$(pnpm root -g)"
node - "$ROOT" <<'NODE'
const root = process.argv[2]
const vueServer = require.resolve('@vue/language-server', { paths: [root] })
const typescript = require.resolve('typescript', { paths: [vueServer] })
const ts = require(typescript)
console.log({
vueServer,
typescript,
version: ts.version,
hasServerProtocol: Boolean(ts.server?.protocol),
})
NODEFor the versions in the question, the last value should be pnpm remove -g @vue/language-server typescript typescript-language-server
pnpm add -g typescript@6.0.3 typescript-language-server@5.3.0 @vue/language-server@3.3.7
hash -rThen restart Emacs (or at least refresh its A project-local installation is even less prone to this problem: pnpm add -D typescript@6.0.3 typescript-language-server@5.3.0 @vue/language-server@3.3.7One more Emacs-specific detail: current |
|
Hey. Thank you so much for the detailed answer. I think now i finally managed to solve the issue after some painful debugging. As you know, typescript version 7.0.0 has been released about two days ago. I just manually pinned the version to 6 and after a The npm/pnpm tools are keep installing the latest release of typescript that actually has some compability issues with the language-server. And this error: Is a first aspect of it. I'll notice the maintainer. Thank you. |
|
@KazariEX I believe the package The package declares: "peerDependencies": { This allows package managers to install unsupported TypeScript versions such as TypeScript 7.x. For example, my pnpm resolves: @vue/language-server@3.3.7 The language server then fails because it relies on TypeScript APIs that are not compatible with this version. |
|
In case this helps someone else... I recently updated to the latest vue-language-server to use with Neovim (Lazyvim) and the lsp started to error on startup, the log contained: I had to go to my I'll see if I can cross post in Lazyvim |
Hey. Thank you so much for the detailed answer. I think now i finally managed to solve the issue after some painful debugging.
As you know, typescript version 7.0.0 has been released about two days ago.
And the thing is, the package
@vue/language-serverdescribes itstypescriptdependency like this:I just manually pinned the version to 6 and after a
pnpm install, the problem solved.The npm/pnpm tools are keep installing the latest release of typescript that actually has some compability issues with the language-server. And this error:
Is a first aspect of it.
I'll notice …