如何使用vim-markdown:Toc:扩展名为.md以外的文档

I am editing long markdown document and it is really good to navigate in them with the :Toc option from vim-markdown. I also edit long .Rmd documents from vim (when the content is more about text than about R code). I have added the following to my ~/.vimrc:

let g:vim_markdown_auto_extension_ext = 'Rmd'                                                  

:Toc works fine in .md documents, but when I enter :Toc in a .Rmd document, I get the error: "E492: Not an editor command: Toc".

评论