svelte, codeaction remove empty, luadev #72

neovim_0.6
ray-x 3 years ago
parent a952d694e1
commit 89b08bc968

@ -49,7 +49,7 @@ local function on_code_action_results(results, ctx)
title = title .. " [newText:]"
for _, ed in pairs(change.edits) do
-- trace(ed)
if ed.newText then
if ed.newText and ed.newText ~= "" then
local newText = ed.newText:gsub("\n\t", "")
newText = newText:gsub("\n", "")
title = title .. " (" .. newText
@ -60,7 +60,7 @@ local function on_code_action_results(results, ctx)
end
end
end
elseif change.newText then
elseif change.newText and change.newText ~= "" then
local newText = change.newText:gsub("\"\n\t\"", "")
newText = newText:gsub("\n", "")
title = title .. " (newText: " .. newText

@ -47,16 +47,15 @@ return {
load = function(plugin_name, path)
local loader = nil
local packer_plugins = packer_plugins or nil -- suppress warnings
local log = require'navigator.util'.log
-- packer only
if packer_plugins ~= nil then -- packer install
local lazy_plugins = {}
lazy_plugins[plugin_name] = path
loader = require"packer".loader
for plugin, url in pairs(lazy_plugins) do
if not packer_plugins[url] or not packer_plugins[url].loaded then
if packer_plugins[plugin] and packer_plugins[plugin].loaded == false then
-- log("loading ", plugin)
loader(plugin)
pcall(loader, plugin)
end
end
end

@ -265,7 +265,7 @@ local servers = {
"jedi_language_server", "jdtls", "sumneko_lua", "vimls", "html", "jsonls", "solargraph", "cssls",
"yamlls", "clangd", "ccls", "sqls", "denols", "graphql", "dartls", "dotls",
"kotlin_language_server", "nimls", "intelephense", "vuels", "phpactor", "omnisharp",
"r_language_server", "rust_analyzer", "terraformls", "svelteserver"
"r_language_server", "rust_analyzer", "terraformls", "svelte"
}
if config.lspinstall == true then

Loading…
Cancel
Save