Open Kycko opened 5 months ago
Do you have the following settings?
"editor.foldingStrategy": "auto",
"editor.defaultFoldingRangeProvider": "zokugun.explicit-folding",
foldingStrategy
is set to auto
by default.
I've changed defaultFoldingRangeProvider
to zokugun.explicit-folding
, but the issue isn't solved.
I've noticed the folding resets only in the files I see when opening VS Code. If the file is opened but it's in other tab, the folding is saved. 🤔
The folding state is managed by VSCode so I would incline to say it's a VSCode bug.
I have also the issue when, sometimes, I have extra foldings. It took me a while to understand it was foldings generated by the default folding provider (before switching to my provider), then saved as "Manual Folding Ranges" by VSCode. Solution: command Remove Manual Folding Ranges
Ran this command, didn't help me.
As I mentioned in https://github.com/microsoft/vscode/issues/189610 the folding state doesn't reset if I disable your extention. Seems there is some conflict in saved folding state and your extention when it's loaded after app start.
Maybe the logs will help?
Describe the issue
VS Code resets all the folding when I close it and open again. I've found the problem in your extention, see https://github.com/microsoft/vscode/issues/189610.
To reproduce
Fold some functions in .gs file (Google Apps Script, language mode JavaScript), close and then open again VS Code. You will see all the functions unfolded.
Code Example
Settings
Expected behavior
Save the folding state after VS Code restarts.
Screenshots