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
Linting / error-checking running VERY slowly #1200
Comments
After update to the latest version, I have the same problem too. |
Can you try to fork https://github.com/octref/veturpack to get a repro? This doesn't repro for me. |
Hi octref. I tried to reproduce the issue but couldn't, leading me to think it is likely something unrelated to Vetur. Thanks for responding to my issue. |
@tedjenkins Can you show me Also how large is your project? |
219MB, including node_modules. This is my package.json:
|
@tedjenkins I have a feeling the perf issues are caused by your PHP extensions rather than Vetur. Can you run the command "Process Explorer" in VS Code to see which one is causing cpu/memory usage? |
@octref Sure thing. |
I'm using typescript too, my teammate notice me that if a |
I do not use PHP extensions but I still get the same problems too. |
Is there any more information you need @octref? |
@octref |
0.18.0 works a a little fast, but still slow, type checking and intellisence still slow. |
Happens to me, too. No PHP extensions, using TypeScript and Vetur. Similar CPU stats. I notice it's a heck of a lot better (but still slow) in smaller files, but slows to an unbearable crawl on even slightly bigger SFCs. Been this way for at least a month now, maybe more. |
My extensions list:
|
I'm experiencing slowness in latest version. Not sure what's causing it tho. |
Also experiencing this. anyone have any leads as to what is causing this? |
Please try to generate a profile and attach it to this issue. It'd help me a lot more than screenshots. |
There's a lot of file system activity going on. It seems to be caused by TypeScript. What's your jsconfig/tsconfig, or you don't have one? I also added some logging for your case. After I publish 0.19.4, can you set |
And then when I edit files to get errors I receive:
etc. My tsconfig.json is as follows:
|
I think the crux of this problem is that I try to load "all files specified from tsconfig.json", when Vetur only needs the *.vue files to work. Just to prove my hypothesis, can you try this pattern and verify if Vetur's features work for you? {
"include": [
"src/**/*.vue"
],
"exclude": [
"node_modules",
"tests/e2e/**/*.ts",
"tests/e2e/**/*.tsx"
"src/**/*.ts",
"src/**/*.tsx",
"tests/unit/**/*.ts",
"tests/unit/**/*.tsx"
]
} |
@octref I think this may break ts files |
@yoyoys I know...Just to see if it breaks Vetur features. If it doesn't I'll need to read the list of files to process in Vetur not from jsconfig/tsconfig. |
@octref I get error code |
I think I have found a good fix. Can you try the VSIX linked here? #1277 (comment) |
This should be fixed in 0.20.0. |
Info
I am also writing the code in TypeScript, latest version.
Problem
When writing code in .vue files, the error-checking functionality lags massively. Screenshot -- note how the error doesn't recognise the entire string (it takes many seconds to recognise it all).
In the Vue Language Server panel I get this output:
Reproducible Case
Open up a .vue file in VS Code with Vetur installed which has
<script lang="ts">...</script>
and write some code, anything at all which should have errors. The error-checking / linting displays, such as the red underline and the popup when you hover over the bad code, will take a long time to recognise all of the error.EDIT: Here is a picture showing how much CPU power and RAM VS Code is taking up when Vetur is in the process of error-checking: https://i.imgur.com/at1ikdf.png
The text was updated successfully, but these errors were encountered: