2021-06-24 13:19:42 -04:00
|
|
|
local M = {}
|
|
|
|
|
|
|
|
M.config = function()
|
|
|
|
require "compe".setup {
|
|
|
|
enabled = true,
|
|
|
|
autocomplete = true,
|
|
|
|
debug = false,
|
|
|
|
min_length = 1,
|
|
|
|
preselect = "enable",
|
|
|
|
throttle_time = 80,
|
|
|
|
source_timeout = 200,
|
|
|
|
incomplete_delay = 400,
|
|
|
|
max_abbr_width = 100,
|
|
|
|
max_kind_width = 100,
|
|
|
|
max_menu_width = 100,
|
|
|
|
documentation = true,
|
|
|
|
source = {
|
|
|
|
buffer = {kind = "", true},
|
2021-06-26 08:50:25 -04:00
|
|
|
luasnip = {kind = "", true},
|
|
|
|
nvim_lsp = true,
|
2021-07-08 23:44:04 -04:00
|
|
|
nvim_lua = true
|
2021-06-24 13:19:42 -04:00
|
|
|
}
|
2021-03-12 20:23:02 -05:00
|
|
|
}
|
2021-03-17 10:37:02 -04:00
|
|
|
end
|
|
|
|
|
2021-06-26 08:50:25 -04:00
|
|
|
M.snippets = function()
|
|
|
|
local ls = require("luasnip")
|
|
|
|
|
|
|
|
ls.config.set_config(
|
|
|
|
{
|
|
|
|
history = true,
|
|
|
|
updateevents = "TextChanged,TextChangedI"
|
|
|
|
}
|
|
|
|
)
|
|
|
|
require("luasnip/loaders/from_vscode").load()
|
|
|
|
end
|
|
|
|
|
2021-06-24 13:19:42 -04:00
|
|
|
return M
|