fix(cmp): only complete on <cr>
when cmp is really visible. Dont wait till it might be visible. Faster and more correct imho
This commit is contained in:
@ -37,7 +37,7 @@ return {
|
||||
["<C-Space>"] = cmp.mapping.complete(),
|
||||
["<C-e>"] = cmp.mapping.abort(),
|
||||
["<CR>"] = function(fallback)
|
||||
if cmp.visible() then
|
||||
if cmp.core.view:visible() or vim.fn.pumvisible() == 1 then
|
||||
LazyVim.create_undo()
|
||||
if cmp.confirm({ select = true }) then
|
||||
return
|
||||
|
Reference in New Issue
Block a user