Open tjx666 opened 1 year ago
Because I add it to codeActions, I can see a big delay after I cmd + s
:
{
"editor.codeActionsOnSave": {
"source.addMissingImports": true,
"source.fixAll.eslint": true,
"source.fixAll.stylelint": true,
"source.fixAll.markdownlint": true,
"source.organizeImports.sortImports": true
},
}
I try to analyze why slow from extension log:
Describe the bug
This happen in a large monorepo project.
Expected behavior
should be faster, my ideal speed is to <= 50ms
Actual behavior
170ms ~ 200ms, however the prettier format can control under 50~100ms
Screenshots
https://user-images.githubusercontent.com/41773861/210131817-ee3f630d-6f0f-4a27-969d-be37a13a3bed.mov
OS (please complete the following information):
System: OS: macOS 13.1 CPU: (8) x64 Intel(R) Core(TM) i5-8257U CPU @ 1.40GHz Memory: 241.86 MB / 16.00 GB Shell: 5.8.1 - /bin/zsh
VS Code (please complete the following information):
package.json (please remove any sensitive info)
tsconfig.json (if any)
.prettierrc/.prettierrc.js/prettier.config.js/.prettierrc.toml (if any) filename:
.editorconfig (if any)
Installed VS Code extensions [Execute
$ code --list-extensions
in terminal to get the list. How to run VS Code from terminal in MacOS]