feat(providers): Inital COC support

Closes #68
Still needs support for code actions/hover/rename etc
This commit is contained in:
simrat39
2021-10-06 12:58:44 -07:00
parent a0d563172d
commit 042c8466a2
6 changed files with 46 additions and 21 deletions

View File

@@ -2,9 +2,24 @@ local M = {}
local providers = {
'symbols-outline/providers/nvim-lsp',
'symbols-outline/providers/coc',
'symbols-outline/providers/markdown'
}
local current_provider;
function M.has_provider()
local ret = false;
for _, value in ipairs(providers) do
local provider = require(value)
if provider.should_use_provider(0) then
ret = true;
break
end
end
return ret
end
---@param on_symbols function
function M.request_symbols(on_symbols)
for _, value in ipairs(providers) do