vscode-powershell
vscode-powershell copied to clipboard
Outline - Optionally treat and show `#` as H1, `##` as H2
Prerequisites
- [x] I have written a descriptive issue title.
- [x] I have searched all issues to ensure it has not already been reported.
Summary
I've written so much markdown that I format my PowerShell scripts and comments by markdown headings.
# First section
## I do something
do-something
## Then I do something else
do-somethingelse
# Second section
do-somethingwithoutputfromfirstsection
It'd be very useful with the ability to show these comments as sections in the outline pane, treat them as markdown headings.
-
#as H1 / level 1 -
##as H2 / level 2 -
###as H3 / level 3
Etc.
I know I can use #region, but I don't like how it looks.
Proposed Design
Maybe a farfetched idea? Not something that should be enabled by default.
{
"powershell.treatCommentsAsMarkdownHeadings": true
}
Thanks for the suggestion! As this isn't a core PowerShell language feature we probably won't implement it, however a separate vscode extension could definitely do this parsing and add that highlighting to vscode.