-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vetur mode fairly slow #11
Comments
Hi there! Thanks for the kind words! Unfortunaly there is not a lot you can do here. Vetur mode means that you are literally using Vetur under the hood, or to better say it you are using the same LSP (Language Server Protocol) which is VLS (Vue Language Server). An LSP is a protocol for sharing language's logic between different editors. What you know as Vetur is just a wrapper of this Language Server for VSCode, just as this plugin is for Nova. Said this way is pretty unfair since the folks behind Vetur are also the folks behind VLS ahaha. What I can tell you is that if you want to solve this you should look to the Vetur LSP itself. @yoyo930021 is a Vetur contributors, maybe he can answer this for you. Anyway the Classic mode will be removed soon. It was just an insurance for the time when Nova LSP support wasn't really good. After some weeks of testing I can say is almost useless. |
Hmm I was afraid that was the case. Makes total sense from a plugin development perspective of course, no need to reinvent that (massive) wheel 😁 I'll look into VLS directly and see if I can find out what's causing this 👍 |
@tommasongr |
Hi @yoyo930021 sorry for reaching out to you again but I'm not sure what is going on here. I tried to upgrade to v0.5.5 and the server throws this error in the console. Vue Language Server[12:08:12.734000] (node:8410) UnhandledPromiseRejectionWarning: Error: Invalid parameter: registrations
Registrations must be of type Registration[]
at handleResponse (/Users/tommaso/Library/Application Support/Nova/Extensions/com.tommasonegri.Vue/dependencyManagement/node_modules/vscode-jsonrpc/lib/common/connection.js:476:48)
at processMessageQueue (/Users/tommaso/Library/Application Support/Nova/Extensions/com.tommasonegri.Vue/dependencyManagement/node_modules/vscode-jsonrpc/lib/common/connection.js:291:17)
at Immediate.<anonymous> (/Users/tommaso/Library/Application Support/Nova/Extensions/com.tommasonegri.Vue/dependencyManagement/node_modules/vscode-jsonrpc/lib/common/connection.js:275:13)
at processImmediate (internal/timers.js:461:21)
(Use `node --trace-warnings ...` to show where the warning was created)
Vue Language Server[12:08:12.735000] (node:8410) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)
Vue Language Server[12:08:12.735000] (node:8410) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. I'm actually following the doc for registering the LSP. Is this is a Nova problem or a problem of the extension? var serverOptions = {
path: path,
}
var clientOptions = {
syntaxes: ['vue'],
}
var client = new LanguageClient(
'tommasonegri.vue',
'Vue Language Server',
serverOptions,
clientOptions
) Thanks again, I should definitely look better into this LSP thing. Unfortunately I haven't really figured it out yet |
I think it's a bug in Nova. You can use |
Hi there!
Thanks for your wonderful work on the Vue plugin 🙂
I've seemed to notice that Nova's version of the Vetur setup has some of the same performance pitfalls as the VS Code original.
For example, when importing a file, it takes a couple seconds for Vetur to "catch up" and show me information, compared to ms on regular .ts files:
My main reason for switching to Nova is the big performance boost compared to it's Electron based contemporaries. Is there something I can do to either speed it up, or help figure out what causes the slowdowns and help fix it? I tried switching to the "Classic" mode of the extension, but that seems to ignore TS in
.vue
filesThe text was updated successfully, but these errors were encountered: