markdowm_preview.vim 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. " set to 1, nvim will open the preview window after entering the markdown buffer
  2. " default: 0
  3. let g:mkdp_auto_start = 0
  4. " set to 1, the nvim will auto close current preview window when change
  5. " from markdown buffer to another buffer
  6. " default: 1
  7. let g:mkdp_auto_close = 0
  8. " set to 1, the vim will refresh markdown when save the buffer or
  9. " leave from insert mode, default 0 is auto refresh markdown as you edit or
  10. " move the cursor
  11. " default: 0
  12. let g:mkdp_refresh_slow = 0
  13. " set to 1, the MarkdownPreview command can be use for all files,
  14. " by default it can be use in markdown file
  15. " default: 0
  16. let g:mkdp_command_for_global = 0
  17. " set to 1, preview server available to others in your network
  18. " by default, the server listens on localhost (127.0.0.1)
  19. " default: 0
  20. let g:mkdp_open_to_the_world = 1
  21. " use custom IP to open preview page
  22. " useful when you work in remote vim and preview on local browser
  23. " more detail see: https://github.com/iamcco/markdown-preview.nvim/pull/9
  24. " default empty
  25. let g:mkdp_open_ip = ''
  26. " specify browser to open preview page
  27. " default: ''
  28. let g:mkdp_browser = ''
  29. " set to 1, echo preview page url in command line when open preview page
  30. " default is 0
  31. let g:mkdp_echo_preview_url = 0
  32. " a custom vim function name to open preview page
  33. " this function will receive url as param
  34. " default is empty
  35. let g:mkdp_browserfunc = ''
  36. " options for markdown render
  37. " mkit: markdown-it options for render
  38. " katex: katex options for math
  39. " uml: markdown-it-plantuml options
  40. " maid: mermaid options
  41. " disable_sync_scroll: if disable sync scroll, default 0
  42. " sync_scroll_type: 'middle', 'top' or 'relative', default value is 'middle'
  43. " middle: mean the cursor position alway show at the middle of the preview page
  44. " top: mean the vim top viewport alway show at the top of the preview page
  45. " relative: mean the cursor position alway show at the relative positon of the preview page
  46. " hide_yaml_meta: if hide yaml metadata, default is 1
  47. " sequence_diagrams: js-sequence-diagrams options
  48. let g:mkdp_preview_options = {
  49. \ 'mkit': {},
  50. \ 'katex': {},
  51. \ 'uml': {},
  52. \ 'maid': {},
  53. \ 'disable_sync_scroll': 0,
  54. \ 'sync_scroll_type': 'middle',
  55. \ 'hide_yaml_meta': 1,
  56. \ 'sequence_diagrams': {},
  57. \ 'flowchart_diagrams': {}
  58. \ }
  59. " use a custom markdown style must be absolute path
  60. " like '/Users/username/markdown.css' or expand('~/markdown.css')
  61. let g:mkdp_markdown_css = ''
  62. " use a custom highlight style must absolute path
  63. " like '/Users/username/highlight.css' or expand('~/highlight.css')
  64. let g:mkdp_highlight_css = ''
  65. " use a custom port to start server or random for empty
  66. let g:mkdp_port = ''
  67. " preview page title
  68. " ${name} will be replace with the file name
  69. let g:mkdp_page_title = '「${name}」'