45 lines
1 KiB
Lua
45 lines
1 KiB
Lua
return {
|
|
{
|
|
"nvim-treesitter/nvim-treesitter",
|
|
opts = function(_, opts)
|
|
if type(opts.ensure_installed) == "table" then
|
|
vim.list_extend(opts.ensure_installed, { "astro" })
|
|
end
|
|
end,
|
|
},
|
|
{
|
|
"neovim/nvim-lspconfig",
|
|
opts = {
|
|
servers = {
|
|
astro = {
|
|
handlers = {
|
|
["textDocument/publishDiagnostics"] = function(err, result, ctx, config)
|
|
require("ts-error-translator").translate_diagnostics(err, result, ctx, config)
|
|
vim.lsp.diagnostic.on_publish_diagnostics(err, result, ctx, config)
|
|
end,
|
|
},
|
|
},
|
|
},
|
|
},
|
|
},
|
|
{
|
|
"dmmulroy/ts-error-translator.nvim",
|
|
opts = {},
|
|
},
|
|
{
|
|
"williamboman/mason.nvim",
|
|
opts = function(_, opts)
|
|
opts.ensure_installed = opts.ensure_installed or {}
|
|
vim.list_extend(opts.ensure_installed, { "astro-language-server" })
|
|
end,
|
|
},
|
|
{
|
|
"luckasRanarison/nvim-devdocs",
|
|
optional = true,
|
|
opts = {
|
|
ensure_installed = {
|
|
"astro",
|
|
},
|
|
},
|
|
},
|
|
}
|