From d0d30fea68b9bcbf698bbe22f22e333df1c5578d Mon Sep 17 00:00:00 2001 From: iGor milhit Date: Tue, 19 Sep 2023 16:33:33 +0200 Subject: [PATCH] markdown: adds the vim-markdown plugins Co-Authored-by: iGor milhit --- after/ftplugin/markdown.lua | 2 +- lua/custom/plugins/vim-markdown.lua | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 lua/custom/plugins/vim-markdown.lua diff --git a/after/ftplugin/markdown.lua b/after/ftplugin/markdown.lua index 3a73708..81e7796 100644 --- a/after/ftplugin/markdown.lua +++ b/after/ftplugin/markdown.lua @@ -4,5 +4,5 @@ -- vim.opt.foldmethod="expr" -- vim.opt.foldexpr="nvim_treesitter#foldexpr()" -vim.g.markdown_folding=1 +-- vim.g.markdown_folding=1 -- vim.opt.foldlevel=1 diff --git a/lua/custom/plugins/vim-markdown.lua b/lua/custom/plugins/vim-markdown.lua new file mode 100644 index 0000000..dd89b1d --- /dev/null +++ b/lua/custom/plugins/vim-markdown.lua @@ -0,0 +1,19 @@ +-- Syntax highlighting, matching rules and mappings for the original Markdown +-- and extensions. +-- https://github.com/preservim/vim-Markdown + +-- Configure the folding style and folding level +vim.cmd([[ let g:vim_markdown_folding_level = 1 ]]) +vim.cmd([[ let g:vim_markdown_folding_style_pythonic = 1 ]]) + +-- Enable the YAML frontmatter support (no highlight yet?) +vim.cmd([[ let g:vim_markdown_frontmatter = 1 ]]) + +return { + { + "preservim/vim-markdown", + ft = { + 'markdown' + } + } +}