diff --git a/.config/nvim/lua/core/keymaps.lua b/.config/nvim/lua/core/keymaps.lua index 514b302..5ba8dd4 100644 --- a/.config/nvim/lua/core/keymaps.lua +++ b/.config/nvim/lua/core/keymaps.lua @@ -295,3 +295,11 @@ keymap( "lua require'ufo'.peekFoldedLinesUnderCursor()", vim.tbl_extend("force", opts, { desc = "Peek fold" }) ) + +-- Markdown +keymap( + "n", + "m", + ":RenderMarkdown toggle", + vim.tbl_extend("force", opts, { desc = "Toggle markdown rendering" }) +) diff --git a/.config/nvim/lua/core/lazy.lua b/.config/nvim/lua/core/lazy.lua index 531d72c..1b8c35b 100644 --- a/.config/nvim/lua/core/lazy.lua +++ b/.config/nvim/lua/core/lazy.lua @@ -249,6 +249,11 @@ require("lazy").setup({ end, ft = { "markdown" }, }, + { + "MeanderingProgrammer/markdown.nvim", + main = "render-markdown", + name = "render-markdown", + }, -- Copilot { diff --git a/.config/nvim/lua/plugins/init.lua b/.config/nvim/lua/plugins/init.lua index 60de393..29ab985 100644 --- a/.config/nvim/lua/plugins/init.lua +++ b/.config/nvim/lua/plugins/init.lua @@ -18,6 +18,7 @@ require("plugins.noice") require("plugins.trouble") require("plugins.autosave") require("plugins.markdowntoc") +require("plugins.render-markdown") require("plugins.diffview") require("plugins.align") require("plugins.ufo") diff --git a/.config/nvim/lua/plugins/render-markdown.lua b/.config/nvim/lua/plugins/render-markdown.lua new file mode 100644 index 0000000..adcb01c --- /dev/null +++ b/.config/nvim/lua/plugins/render-markdown.lua @@ -0,0 +1,5 @@ +require("render-markdown").setup({ + bullet = { + icons = { "·", "·", "·", "·" }, + }, +})