Setup tailwind, eslint and other LSP stuff
This commit is contained in:
parent
9351fb8460
commit
7b8c05de4d
@ -30,11 +30,6 @@ require'lspconfig'.tsserver.setup({
|
|||||||
includeInlayFunctionLikeReturnTypeHints = true,
|
includeInlayFunctionLikeReturnTypeHints = true,
|
||||||
includeInlayEnumMemberValueHints = true,
|
includeInlayEnumMemberValueHints = true,
|
||||||
}
|
}
|
||||||
},
|
|
||||||
["rust-analyzer"] = {
|
|
||||||
checkOnSave = {
|
|
||||||
command = 'clippy'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -50,7 +45,41 @@ require'lspconfig'.rust_analyzer.setup {
|
|||||||
includeInlayPropertyDeclarationTypeHints = true,
|
includeInlayPropertyDeclarationTypeHints = true,
|
||||||
includeInlayFunctionLikeReturnTypeHints = true,
|
includeInlayFunctionLikeReturnTypeHints = true,
|
||||||
includeInlayEnumMemberValueHints = true,
|
includeInlayEnumMemberValueHints = true,
|
||||||
|
},
|
||||||
|
checkOnSave = {
|
||||||
|
command = 'clippy'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
require('lspconfig').tailwindcss.setup({
|
||||||
|
settings = {
|
||||||
|
tailwindCSS = {
|
||||||
|
experimental = {
|
||||||
|
classRegex = {
|
||||||
|
{ "tv\\((([^()]*|\\([^()]*\\))*)\\)", "[\"'`]([^\"'`]*).*?[\"'`]" }
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
require 'lspconfig'.eslint.setup({
|
||||||
|
settings = {
|
||||||
|
packageManager = 'npm'
|
||||||
|
},
|
||||||
|
on_attach = function(client, bufnr)
|
||||||
|
vim.api.nvim_create_autocmd("BufWritePre", {
|
||||||
|
buffer = bufnr,
|
||||||
|
command = "EslintFixAll",
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
|
||||||
|
lspconfig.graphql.setup({
|
||||||
|
root_dir = lspconfig.util.root_pattern(".graphqlconfig", ".graphqlrc", "package.json"),
|
||||||
|
flags = {
|
||||||
|
debounce_text_changes = 150,
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|||||||
@ -89,6 +89,7 @@ return require('packer').startup(function()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
use { "nvim-neotest/nvim-nio" }
|
||||||
use 'mfussenegger/nvim-dap'
|
use 'mfussenegger/nvim-dap'
|
||||||
use 'mfussenegger/nvim-jdtls' -- Java
|
use 'mfussenegger/nvim-jdtls' -- Java
|
||||||
use { "rcarriga/nvim-dap-ui", requires = {"mfussenegger/nvim-dap"} }
|
use { "rcarriga/nvim-dap-ui", requires = {"mfussenegger/nvim-dap"} }
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user