aerial.nvim
aerial.nvim copied to clipboard
feature request: foldmarker support
Did you check existing requests?
- [X] I have searched the existing issues
Describe the feature
when using fdm=marker and there's no treesitter/lsp/etc, use foldmarkers as a fallback, with the line as the name of the symbol, so that
# section 1 {{{1
# subsection 1.1 {{{2
# ...
# subsection 1.2 {{{2
would become
section 1
├── subsection 1.1
└── subsection 1.2
Provide background
long configs, especially ones where you can't include/import from a separate file
What is the significance of this feature?
nice to have
Additional details
the marker can be removed with
string.gsub(line, string.gsub(vim.o.foldmarker, ',.*', '') .. '%d*', '')
not sure if it's possible to use the builtin comment function tho
This is a neat idea. Would probably require building a custom backend, like we did for asciidoc