hopefully fix typescript checking in vue files

This commit is contained in:
Mark Riedesel 2024-08-07 11:14:34 -05:00
parent 85080081bc
commit a61051f82b
5 changed files with 55 additions and 1 deletions

View file

@ -0,0 +1,6 @@
return {
"David-Kunz/gen.nvim",
opts = {
model = "mistral",
},
}

View file

@ -133,8 +133,38 @@ return {
}) })
end, end,
lspconfig.gdscript.setup({}) ["tsserver"] = function ()
local mason_registry = require 'mason-registry'
local vue_language_server_path = mason_registry.get_package('vue-language-server'):get_install_path()
lspconfig['tsserver'].setup({
init_options = {
plugins = {
{
name = '@vue/typescript-plugin',
location = vue_language_server_path,
languages = { 'vue' },
},
},
},
}) })
end, end,
["volar"] = function ()
lspconfig['volar'].setup {
init_options = {
vue = {
hybridMode = false,
},
},
filetypes = {
'vue',
},
}
end,
})
lspconfig.gdscript.setup {}
end,
} }

View file

@ -21,6 +21,8 @@ return {
package_pending = "", package_pending = "",
package_uninstalled = "", package_uninstalled = "",
}, },
width = 0.8,
height = 0.9,
}, },
}) })

View file

@ -0,0 +1,14 @@
return {
"nvim-treesitter/nvim-treesitter-textobjects",
lazy = true,
config = function ()
require("nvim-treesitter.configs").setup({
textobjects = {
select = {
enable = true,
lookahead = true,
},
},
})
end
}

View file

@ -4,6 +4,7 @@ return {
build = ":TSUpdate", build = ":TSUpdate",
dependencies = { dependencies = {
"windwp/nvim-ts-autotag", "windwp/nvim-ts-autotag",
"nvim-treesitter/nvim-treesitter-textobjects",
}, },
config = function() config = function()
-- import nvim-treesitter plugin -- import nvim-treesitter plugin
@ -11,6 +12,7 @@ return {
-- configure treesitter -- configure treesitter
treesitter.setup({ -- enable syntax highlighting treesitter.setup({ -- enable syntax highlighting
auto_install = true,
highlight = { highlight = {
enable = true, enable = true,
}, },