tsserver safety buffer exits and settings

This commit is contained in:
Thomas Smallwood 2025-11-25 17:43:06 +00:00
parent 6f39b5d1d3
commit c1254fd7a6
No known key found for this signature in database
2 changed files with 21 additions and 1 deletions

View file

@ -9,3 +9,10 @@ vim.o.scrolloff = 10
-- Semantic highlighting
vim.g.lazyvim_semantic_highlighting = false
-- Kill any orphaned tsserver processes when Neovim exits
vim.api.nvim_create_autocmd("ExitPre", {
callback = function()
vim.fn.system("pkill -f 'tsserver.js'")
end,
})

View file

@ -19,6 +19,19 @@ return {
"javascript",
"javascriptreact",
},
opts = {},
opts = {
settings = {
tsserver_file_preferences = {
disableSuggestions = false,
includeInlayParameterNameHints = "all",
includeCompletionsForModuleExports = true,
},
tsserver_enable_partial_semantic_mode = true,
tsserver_watch_options = {
watchFile = "useFsEvents", -- recommended for remote/container
watchDirectory = "useFsEvents",
},
},
},
},
}