LazyVim.LazyVim/lua/lazyvim/plugins/extras/lang/typst.lua

73 lines
1.2 KiB
Lua
Raw Normal View History

2024-07-15 10:43:37 +07:00
return {
recommended = function()
return LazyVim.extras.wants({
ft = { "typst" },
})
end,
{
"nvim-treesitter/nvim-treesitter",
opts = {
ensure_installed = { "typst" },
},
},
2024-09-13 08:35:22 +07:00
{
"williamboman/mason.nvim",
opts = {
ensure_installed = { "typstyle" },
},
},
2024-07-15 10:43:37 +07:00
{
"neovim/nvim-lspconfig",
opts = {
servers = {
tinymist = {},
},
},
},
{
"stevearc/conform.nvim",
optional = true,
2024-07-15 10:43:37 +07:00
opts = {
formatters_by_ft = {
typst = { "typstyle" },
},
},
},
2024-07-15 14:06:14 +07:00
{
"nvimtools/none-ls.nvim",
optional = true,
opts = function(_, opts)
local nls = require("null-ls")
opts.sources = vim.list_extend(opts.sources or {}, {
nls.builtins.formatting.typstyle,
})
end,
},
2024-07-15 10:43:37 +07:00
{
"chomosuke/typst-preview.nvim",
cmd = { "TypstPreview" },
build = function()
require("typst-preview").update()
end,
keys = {
{
"<leader>cp",
ft = "typst",
"<cmd>TypstPreviewToggle<cr>",
desc = "Typst Preview",
},
},
2024-07-15 10:43:37 +07:00
opts = {
dependencies_bin = {
["typst-preview"] = "tinymist",
},
},
},
}