summaryrefslogtreecommitdiffstats
path: root/plugin/50-markdown.lua
blob: f7c3de5f3cc78ba92f3f38777a95334e7c46828c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
--
-- 50-markdown.lua
--
-- * Installs the treesitter parsers used when rendering markdown.
-- * Configures `render-markdown` (https://github.com/MeanderingProgrammer/render-markdown.nvim).
--

require("nvim-treesitter").install({
	"html",
	"latex",
	"markdown",
	"markdown_inline",
	"yaml",
})

local markdown_textwidth = vim.g.dotfiles.textwidth.markdown
require("render-markdown").setup({
	heading = { min_width = markdown_textwidth },
	code = {
		position = "center",
		sign = false,
		width = "block",
		min_width = markdown_textwidth / 2,
	},
	dash = { width = markdown_textwidth },
	win_options = { conceallevel = { rendered = 2 } },
})