Skip to content

Commit

Permalink
fix(markview-nvim): add smarter lazy loading on filetype
Browse files Browse the repository at this point in the history
  • Loading branch information
mehalter committed Sep 5, 2024
1 parent 898e8f7 commit 40497b1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lua/astrocommunity/markdown-and-latex/markview-nvim/init.lua
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
return {
"OXY2DEV/markview.nvim",
ft = { "markdown", "markdown.mdx" },
ft = function()
local plugin = require("lazy.core.config").spec.plugins["render-markdown.nvim"]

This comment has been minimized.

Copy link
@tku137

tku137 Sep 9, 2024

Contributor

Is this intentionally another plugins spec? I started getting errors on starting nvim because there is no "render-markdown.nvim" spec, because I used to have markview.nvim without render-markdown.nvim. In any way, markview.nvim should work without render-markdown.nvim?

This comment has been minimized.

Copy link
@mehalter

mehalter Sep 9, 2024

Author Member

nope it's not! :D

local opts = require("lazy.core.plugin").values(plugin, "opts", false)
return opts.filetypes or { "markdown", "quarto", "rmd" }
end,
dependencies = {
"nvim-treesitter/nvim-treesitter",
opts = function(_, opts)
Expand Down

0 comments on commit 40497b1

Please sign in to comment.