aboutsummaryrefslogtreecommitdiff
path: root/init.lua
diff options
context:
space:
mode:
authorShashwat Agrawal <shashwatagrawal473@gmail.com>2023-11-11 20:31:05 +0530
committerShashwat Agrawal <shashwatagrawal473@gmail.com>2023-11-11 20:31:05 +0530
commitaf4f51b2cd6cfb2511d34adc99900110f4d3916b (patch)
treeb9a275a0d569cee24d49b85821966e2b2549a741 /init.lua
parenta005f15cec8072c97201f86e15df62c7e4a4490e (diff)
fix(auto-completion): ensure first menu item is selected by default
Diffstat (limited to 'init.lua')
-rw-r--r--init.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/init.lua b/init.lua
index 748e7f8..385b19a 100644
--- a/init.lua
+++ b/init.lua
@@ -564,6 +564,9 @@ cmp.setup {
luasnip.lsp_expand(args.body)
end,
},
+ completion = {
+ completeopt = 'menu,menuone,noinsert'
+ },
mapping = cmp.mapping.preset.insert {
['<C-n>'] = cmp.mapping.select_next_item(),
['<C-p>'] = cmp.mapping.select_prev_item(),