Skip to content

Commit

Permalink
refactor: typescript - tsserver/vtsls (#47)
Browse files Browse the repository at this point in the history
- refactor(vtsls): extract to own server config
- refactor(vtsls): set filetypes for plugin
  • Loading branch information
snelling-a authored May 11, 2023
2 parents 25a3f09 + 1d037f9 commit 6bc8dcd
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lua/config/lsp/server/tsserver.lua
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ local settings = {
function Tsserver.setup(opts)
opts.root_dir = util.get_root_pattern(config_files)

lspconfig.vtsls.setup(opts)
-- lspconfig.vtsls.setup(opts)

opts.settings = settings

Expand Down
5 changes: 5 additions & 0 deletions lua/config/lsp/server/vtsls.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
local M = {}

function M.setup(opts) require("lspconfig").vtsls.setup(opts) end

return M
2 changes: 1 addition & 1 deletion lua/plugins/lspconfig.lua
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ M.dependencies = {
"jparise/vim-graphql",
"lvimuser/lsp-inlayhints.nvim",
"SmiteshP/nvim-navic",
"yioneko/nvim-vtsls",
{ "yioneko/nvim-vtsls", ft = { "typescript", "typescriptreact", "javascript", "javascriptreact" } },
{
"williamboman/mason.nvim",
opts = {
Expand Down

0 comments on commit 6bc8dcd

Please sign in to comment.