You've already forked dotfiles
feat: Working on filling in the gaps of LSPs, this time with html
language support.
This commit is contained in:
19
nvim/after/lsp/html.lua
Normal file
19
nvim/after/lsp/html.lua
Normal file
@@ -0,0 +1,19 @@
|
||||
return {
|
||||
cmd = function(dispatchers, _)
|
||||
return vim.lsp.rpc.start({'vscode-html-language-server', '--stdio' }, dispatchers)
|
||||
end,
|
||||
filetypes = { 'html' },
|
||||
init_options = {
|
||||
provideFormatter = true,
|
||||
configurationSection = { 'html', 'css', 'javascript' },
|
||||
embeddedLanguages = {
|
||||
css = true,
|
||||
javascript = true
|
||||
}
|
||||
},
|
||||
root_markers = { 'package.json', '.git' },
|
||||
-- root_dir = function(fname)
|
||||
-- return root_pattern(fname) or vim.loop.os_homedir()
|
||||
-- end,
|
||||
settings = {},
|
||||
}
|
||||
@@ -1 +1,8 @@
|
||||
return {}
|
||||
return {
|
||||
cmd = { 'R', '--slave', '-e', 'languageserver::run()' },
|
||||
filetypes = { 'r', 'rmd' },
|
||||
log_level = 2,
|
||||
root_dir = function(fname)
|
||||
return util.find_git_ancestor(fname) or vim.loop.os_homedir()
|
||||
end,
|
||||
}
|
||||
|
||||
@@ -55,6 +55,7 @@ local enabled_lsps = {
|
||||
'clangd',
|
||||
'bashls',
|
||||
'gdscript',
|
||||
'html',
|
||||
'intelephense',
|
||||
'jinja_lsp',
|
||||
'lua_ls',
|
||||
@@ -68,3 +69,11 @@ local enabled_lsps = {
|
||||
for _, lsp in pairs(enabled_lsps) do
|
||||
vim.lsp.enable(lsp)
|
||||
end
|
||||
|
||||
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
||||
|
||||
capabilities.textDocument.completion.completionItem.snippetSupport = true
|
||||
|
||||
vim.lsp.config('*', {
|
||||
capabilities = capabilities,
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user