Add cmp.event:on() (#418)

This commit is contained in:
hrsh7th
2021-10-28 11:02:19 +09:00
committed by GitHub
parent d113902eef
commit 1c498a5497
5 changed files with 40 additions and 9 deletions

View File

@@ -414,10 +414,6 @@ cmp.setup {
}
```
#### event.on_confirm_done (type: fun(entry: cmp.Entry))
A callback function called when the item is confirmed.
#### experimental.native_menu (type: boolean)
Use vim's native completion menu instead of custom floating menu.
@@ -476,6 +472,12 @@ Programatic API
You can use the following APIs.
#### `cmp.event:on(name: string, callback: string)`
Subscribe the following events.
- `confirm_done`
#### `cmp.visible()`
Return the completion menu is visible or not.