camel-lsp-client-vscode
camel-lsp-client-vscode copied to clipboard
Normal YAML does not have code folding option with this extension enabled
Normal YAML does not have code folding option with this extension enabled
BUG report
Environment
-
Language Support for Apache Camel version: e.g. "v0.0.13" ? 0.0.35
-
OS:
- [ ] Linux (RHEL, Fedora, Ubuntu, ...)
- [x ] Windows
- [ ] macOS
Description of wrong behavior
I am opening non-camel project which contains yml
file. I do not get code folding. If I disable the extension code folding for yaml works
Screenshot (optional)
When extension is enabled
When extension is disabled
The folding that we can see in the screenshot is the indentation-based one provided by VS Code. The yaml language server is nto providing one https://github.com/redhat-developer/yaml-language-server/blob/27daa94333f7c0567978d891dfa5dbd334f8af09/src/yamlServerInit.ts#L106 it sounds like a limitation of VS Code which doesn't allow to have indentation based and foldingRange provider used at the same time. In settings, there are only 2 options auto and indentation-based but not the mix of both of them.
Workaround without uninstalling VS Code Camel Language: File -> Preferences -> Settings -> Text Editor -> Folding Strategy -> Indentation
reported enhancement request https://github.com/microsoft/vscode/issues/135279