mirror of
https://github.com/prabirshrestha/asyncomplete.vim.git
synced 2026-06-08 15:37:06 +02:00
use a:ctx['col'] and a:ctx['typed']
This commit is contained in:
@@ -23,8 +23,8 @@ asyncomplete.vim deliberately does not contain any sources. Please use one of th
|
||||
|
||||
```vim
|
||||
function! s:js_completor(opt, ctx) abort
|
||||
let l:col = col('.')
|
||||
let l:typed = strpart(getline('.'), 0, l:col)
|
||||
let l:col = a:ctx['col']
|
||||
let l:typed = a:ctx['typed']
|
||||
|
||||
let l:kw = matchstr(l:typed, '\v\S+$')
|
||||
let l:kwlen = len(l:kw)
|
||||
|
||||
Reference in New Issue
Block a user