-
Notifications
You must be signed in to change notification settings - Fork 64
Open
Description
I created a new nvim setup and I cannot get typescript-tools
to attach to my file as LSP. There is typescript installed locally (also tried globally). I am opening normal .ts
files. The ts_ls
is removed from Mason (this is correct, right? It should directly connect to the typescript of the project, if I understand correctly).
My current lsp config:
return {
{
"williamboman/mason.nvim",
lazy = false,
opts = {}
},
{
"williamboman/mason-lspconfig.nvim",
lazy = false,
dependencies = {
"williamboman/mason.nvim",
"neovim/nvim-lspconfig",
},
opts = {
ensure_installed = {
"lua_ls"
}
},
},
{
"neovim/nvim-lspconfig",
lazy = false,
config = function()
local lspconfig = require("lspconfig")
lspconfig.lua_ls.setup({
settings = {
Lua = {
runtime = {
-- Tell the language server which version of Lua you're using
-- (most likely LuaJIT in the case of Neovim)
version = 'LuaJIT',
},
diagnostics = {
-- Get the language server to recognize the `vim` global
globals = {
'vim',
'require'
},
},
workspace = {
-- Make the server aware of Neovim runtime files
library = vim.api.nvim_get_runtime_file("", true),
},
-- Do not send telemetry data containing a randomized but unique identifier
telemetry = {
enable = false,
},
},
}
})
end,
},
{
"pmizio/typescript-tools.nvim",
dependencies = { "nvim-lua/plenary.nvim", "neovim/nvim-lspconfig" },
}
}
And here is the :LspInfo, in which I would expect typescript-tools
to be attached, right?
==============================================================================
vim.lsp: ✅
- LSP log level : WARN
- Log path: /Users/username/.local/state/nvim/lsp.log
- Log size: 122 KB
vim.lsp: Active Clients ~
- No active clients
vim.lsp: Enabled Configurations ~
- lua_ls:
- cmd: { "lua-language-server" }
- filetypes: lua
- root_markers: .luarc.json, .luarc.jsonc, .luacheckrc, .stylua.toml, stylua.toml, selene.toml, selene.yml, .git
vim.lsp: File Watcher ~
- file watching "(workspace/didChangeWatchedFiles)" disabled on all clients
vim.lsp: Position Encodings ~
- No active clients
Thank you very much for every hint. Right now I am out of ideas.
Metadata
Metadata
Assignees
Labels
No labels