Vim snippets¶
- snipmate-to-json
- Convert snippets in SnipMate format to JSON, as used by VSCode and other snippet plugins.
Snippet collections¶
Snippet engines¶
Luasnip¶
- GitHub
- Lua
- Available as Lazyim extra
- Supports: VScode, Snipmate, Lua snippets
blink.cmp¶
nvim-snippets¶
- GitHub
- "Snippet support using native neovim snippets"
- Uses vim.snippet under the hood for snippet expansion
- Default snippet engine in LazyVim
- Supports vscode style snippets, i.e. friendly-snippets
- Example snippet
- Snippet search path:
~/.config/nvim/snippets
UltiSnips¶
Show list of snippets available for filetype: <F2>
Otherwise <tab> will complete snippets.
Snippet syntax¶
Vscode / LSP syntax¶
- LSP snippetSyntax docs
- Snippet collections: friendly-snippets Set of preconfigured snippets for different languages
- Disadvantage: JSON :/
- Example shell snippets
Snipmate snippets¶
- Snipmate snippet syntax is easy to read and maintain
- Can't find a syntax documentation source of truth
- LuaSnip docs for Snipmate syntax
- Original vim-snipmate plugin
- honza/vim-snippets
- Example shell snippets
Lua snippets¶
- Available as Lazyim extra
- Horrible Lua snippet syntax
- LuaSnip-snippets.nvim Neovim plugin that provides snippets for the LuaSnip plugin
Ultisnip syntax¶
- Extensible
- Example snippets from honza/vim-snippets
Other¶
- nvim-cmp supported snippet engines
- nvim-snippy
- SnipMate compatibles
- Supports
honza/vim-snippets
- vsnip
- VimScript
- neosnippet
- Vimscript
Note: Active development on neosnippet.vim has stopped.The only future changes will be bug fixes.