markdown-preview.vim
markdown-preview.vim copied to clipboard
Mapping MarkdownPreview doesn't work in insert mode
I have the following settings in my .vimrc
:
let g:mkdp_command_for_global = 1
nmap <silent> <F8> <Plug>MarkdownPreview
imap <silent> <F8> <Plug>MarkdownPreview
nmap <silent> <F9> <Plug>StopMarkdownPreview
imap <silent> <F9> <Plug>StopMarkdownPreview
Pressing F8
in insert mode opens a new Chrome tab with an empty preview. The tab can't be closed with F9
in any other mode. Both F8
and F9
work as expected in normal mode. Mapping to different key combos doesn't solve the problem.
Otherwise a great plugin! Definitely the best one from the few I've tried.
sorry i can‘t reproduced this. maybe it's some issue when lanuch the service and browser
I tested it on two computers (Arch Linux and a musl-based Void Linux), both running dwm window manager and chromium web browser provided by the package manager.