-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
1-coding.lua
63 lines (63 loc) · 1.5 KB
/
1-coding.lua
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
return {
-- Jsdoc
{
"heavenshell/vim-jsdoc",
ft = "javascript,typescript,typescriptreact,svelte",
cmd = "JsDoc",
keys = {
{ "<leader>jd", "<cmd>JsDoc<cr>", desc = "JsDoc" },
},
build = "make install",
},
-- Add Tailwind CSS LSP
{
"williamboman/mason.nvim",
opts = {
ensure_installed = {
"stylua",
-- rustywind for tailwindcss
"tailwindcss-language-server",
"rustywind",
},
},
},
-- Markdown
{
"lukas-reineke/headlines.nvim",
opts = function()
local opts = {}
for _, ft in ipairs({ "markdown", "norg", "rmd", "org" }) do
opts[ft] = { headline_highlights = {} }
for i = 1, 6 do
table.insert(opts[ft].headline_highlights, "Headline" .. i)
end
end
return opts
end,
ft = { "markdown", "norg", "rmd", "org" },
config = function(_, opts)
-- PERF: schedule to prevent headlines slowing down opening a file
vim.schedule(function()
require("headlines").setup(opts)
require("headlines").refresh()
end)
end,
},
-- Markdown preview
{
"previm/previm",
config = function()
-- define global for open markdown preview, let g:previm_open_cmd = 'open -a Safari'
vim.g.previm_open_cmd = "open -a Arc"
end,
ft = { "markdown" },
keys = {
-- add <leader>mp to open markdown preview
{
"<leader>mp",
"<cmd>PrevimOpen<cr>",
desc = "Markdown preview",
},
},
},
}