[BUG] "Create ToC" not working
DehanLUO opened this issue · 1 comments
DehanLUO commented
Describe the bug
Hi.
Using this package in MacOS12.3. When I use the command Create ToC in the command pallette, only the below line is appended.
<!-- @import "[TOC]" {cmd:"toc", depthFrom:1, depthTo:6, orderedList:false} -->
Headings are not generated below the above insertion.
Let me know if you need more details. Thanks.
Result from CocInfo
## versions
vim version: VIM - Vi IMproved 8.2 8023455
node version: v17.5.0
coc.nvim version: 0.0.80-ccd0b050e0
coc.nvim directory: /Users/dehan/.vim/plugged/coc.nvim
term: Apple_Terminal
platform: darwin
## Log of coc.nvim
2022-03-10T02:42:22.954 INFO (pid:14454) [plugin] - coc.nvim initialized with node: v17.5.0 after 831ms
2022-03-10T02:43:12.246 INFO (pid:14454) [attach] - receive notification: runCommand [ 'markdown-preview-enhanced.openPreview' ]
2022-03-10T02:43:28.014 INFO (pid:14454) [attach] - receive notification: runCommand [ 'markdown-preview-enhanced.runAllCodeChunks' ]
2022-03-10T02:48:53.001 INFO (pid:14454) [attach] - receive notification: runCommand [ 'markdown-preview-enhanced.createTOC' ]
2022-03-10T02:49:46.625 INFO (pid:14454) [attach] - receive notification: runCommand [ 'markdown-preview-enhanced.runAllCodeChunks' ]
2022-03-10T02:50:06.100 INFO (pid:14454) [attach] - receive notification: runCommand [ 'markdown-preview-enhanced.openPreview' ]
2022-03-10T02:52:28.313 INFO (pid:14454) [attach] - receive notification: showInfo []
2022-03-10T02:52:45.318 INFO (pid:14454) [attach] - receive notification: runCommand [ 'markdown-preview-enhanced.createTOC' ]
2022-03-10T02:53:07.711 INFO (pid:14454) [attach] - receive notification: showInfo []
Steps to reproduce
Steps to reproduce the behavior:
- execute
vim
:CocCommand markdown-preview-enhanced.openPreview
- clicked on the first symbol and this opened the side bar having the TOC
:CocCommand markdown-preview-enhanced.createTOC
:w
Save my markdown file.- Nothing else happens on save. Toc is not embedded.
Expected behavior
Toc is embedded correctly.
Thanks.
DehanLUO commented
Thanks. It works.
Have a good day