sassoftware / vscode-sas-extension

This SAS Extension for Visual Studio Code provides support for the SAS language, including features such as SAS syntax highlighting, code completion, hover help, code folding, outline, SAS code snippets and run SAS code.
https://sassoftware.github.io/vscode-sas-extension/
Apache License 2.0
113 stars 47 forks source link

Support for code folding for %if and %do #1095

Open Criptic opened 1 month ago

Criptic commented 1 month ago

Is your feature request related to a problem? Please describe. There is already a lot of ways to fold code on a proc, macro level, but what is missing are macro if and macro do statements.

Describe the solution you'd like Provide the ability to fold the code also when using %do and %if.

Describe alternatives you've considered None

Additional context Add any other context or screenshots about the feature request here.

Environment SAS version: 2024.06

scnwwu commented 1 month ago

If your code is indented well, a workaround is to set the setting editor.foldingStrategy to indentation and it can fold at each indentation.

Criptic commented 1 month ago

@scnwwu that is a great idea and works well for me as I use indentation a lot!