Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nvimdev/epo.nvim
A blazing fast and minimal neovim autocompletion
https://github.com/nvimdev/epo.nvim
Last synced: about 1 month ago
JSON representation
A blazing fast and minimal neovim autocompletion
- Host: GitHub
- URL: https://github.com/nvimdev/epo.nvim
- Owner: nvimdev
- License: mit
- Created: 2023-10-17T00:27:47.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2024-02-20T11:03:03.000Z (3 months ago)
- Last Synced: 2024-02-22T12:36:39.856Z (3 months ago)
- Language: Lua
- Size: 44.9 KB
- Stars: 96
- Watchers: 5
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Lists
- awesome-neovim - nvimdev/epo.nvim - Blazingly fast, minimal LSP auto-completion and snippet engine. (Completion / (requires Neovim 0.5))
- awesome-stars - nvimdev/epo.nvim - A blazing fast and minimal neovim autocompletion (Lua)
- awesome-neovim - nvimdev/epo.nvim - Blazingly fast, minimal LSP auto-completion and snippet engine. (Completion / (requires Neovim 0.5))
- awesome-neovim - nvimdev/epo.nvim - Blazingly fast, minimal LSP auto-completion and snippet engine. (Completion / (requires Neovim 0.5))
README
## epo.nvim
Blazingly fast, minimal lsp auto-completion and snippet plugin for neovim.
**Needs neovim nightly**
**This plugin would be much more feature-complete after [this pr](https://github.com/neovim/neovim/pull/24723) is merged**
## Usage
```lua
-- suggested completeopt
vim.opt.completeopt = "menu,menuone,noselect"-- default settings
require('epo').setup({
-- fuzzy match
fuzzy = false,
-- increase this value can aviod trigger complete when delete character.
debounce = 50,
-- when completion confrim auto show a signature help floating window.
signature = false,
-- vscode style json snippet path
snippet_path = nil,
-- border for lsp signature popup, :h nvim_open_win
signature_border = 'rounded',
-- lsp kind formatting, k is kind string "Field", "Struct", "Keyword" etc.
kind_format = function(k)
return k:lower():sub(1, 1)
end
})
```You may want to pass the capabilities to your lsp
```lua
local capabilities = vim.tbl_deep_extend(
'force',
vim.lsp.protocol.make_client_capabilities(),
require('epo').register_cap()
)
```Completion menu look dull and boring? Your colorscheme may be missing these highlights:
```
Pmenu
PmenuExtra
PmenuSel
PmenuKind
PmenuKindSel
PmenuExtraSel
PmenuSbar
PmenuThumb
```Click to show some mapping presets
- TAB complete
```lua
vim.keymap.set('i', '', function()
if vim.fn.pumvisible() == 1 then
return ''
elseif vim.snippet.jumpable(1) then
return 'lua vim.snippet.jump(1)'
else
return ''
end
end, { expr = true })vim.keymap.set('i', '', function()
if vim.fn.pumvisible() == 1 then
return ''
elseif vim.snippet.jumpable(-1) then
return 'lua vim.snippet.jump(-1)'
else
return ''
end
end, { expr = true })vim.keymap.set('i', '', function()
if vim.fn.pumvisible() == 1 then
require('epo').disable_trigger()
end
return ''
end, {expr = true})
```- use `` to accept completion
```lua
-- For using enter as completion, may conflict with some autopair plugin
vim.keymap.set("i", "", function()
if vim.fn.pumvisible() == 1 then
return ""
end
return ""
end, { expr = true, noremap = true })-- nvim-autopair compatibility
vim.keymap.set("i", "", function()
if vim.fn.pumvisible() == 1 then
return ""
end
return require("nvim-autopairs").autopairs_cr()
end, { expr = true, noremap = true })
```## License MIT