Can I set the. Complete key for the code?

  question, vim

. vimrc
autocmd FileType javascript set omnifunc=javascriptcomplete#CompleteJS

When editing js files, enter
Document., then enter
CTRL+X ,CTRL+O to display the completion menu
图片描述
Can it be done?

Do you want to jump out of the completion menu?

The simplest.Map to<C-X><C-O>Just do it.

imap . <C-X><C-O>