Skip to content

Commit

Permalink
feat: Add markdown-preview (optionally)
Browse files Browse the repository at this point in the history
  • Loading branch information
Allaman committed Apr 23, 2024
1 parent 631ca72 commit e0c4019
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions lua/core/plugins/markdown-preview.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
local user_config = vim.g.config.plugins.markdown_preview or {}

local default_config = {
enabled = false,
opts = {},
}

local config = vim.tbl_deep_extend("force", default_config, user_config)

return {
"iamcco/markdown-preview.nvim",
enabled = config.enabled,
cmd = { "MarkdownPreviewToggle", "MarkdownPreview", "MarkdownPreviewStop" },
ft = { "markdown" },
build = function()
vim.fn["mkdp#util#install"]()
end,
}

0 comments on commit e0c4019

Please sign in to comment.