From 2c3103a04aabaf316fcb80e01a03baddcbb5e35e Mon Sep 17 00:00:00 2001 From: Jose Storopoli Date: Sat, 14 Sep 2024 05:31:18 -0300 Subject: [PATCH] feat(extras): lang typst Adds [`typst`](https://typst.app) support with preview. --- lua/lazyvim/plugins/extras/lang/typst.lua | 35 +++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 lua/lazyvim/plugins/extras/lang/typst.lua diff --git a/lua/lazyvim/plugins/extras/lang/typst.lua b/lua/lazyvim/plugins/extras/lang/typst.lua new file mode 100644 index 00000000..20aaf9ed --- /dev/null +++ b/lua/lazyvim/plugins/extras/lang/typst.lua @@ -0,0 +1,35 @@ +return { + recommended = function() + return LazyVim.extras.wants({ + ft = { "typst" }, + }) + end, + { + "nvim-treesitter/nvim-treesitter", + opts = { ensure_installed = { "typst" } }, + }, + { + "neovim/nvim-lspconfig", + opts = { + servers = { + typst_lsp = {}, + }, + }, + }, + -- Typst preview + { + "chomosuke/typst-preview.nvim", + ft = "typst", + build = function() + require("typst-preview").update() + end, + keys = { + { + "cp", + ft = "typst", + "TypstPreviewToggle", + desc = "Typst Preview", + }, + }, + }, +}