Disable coc bindings when coc not loaded.
This commit is contained in:
parent
3ab0a641a4
commit
69518afa81
1 changed files with 18 additions and 15 deletions
|
@ -59,6 +59,8 @@ let g:vimspector_install_gadgets = ['debugpy']
|
|||
|
||||
" Config for Coc originally from their github.
|
||||
" Use tab for trigger completion with characters ahead and navigate
|
||||
" If node is not available Coc will not be loaded so disable.
|
||||
if executable('node') " Coc only works if nodejs is available.
|
||||
inoremap <silent><expr> <TAB>
|
||||
\ coc#pum#visible() ? coc#pum#next(1) :
|
||||
\ CheckBackspace() ? "\<Tab>" :
|
||||
|
@ -77,3 +79,4 @@ function! CheckBackspace() abort
|
|||
let col = col('.') - 1
|
||||
return !col || getline('.')[col - 1] =~# '\s'
|
||||
endfunction
|
||||
endif
|
||||
|
|
Loading…
Reference in a new issue