Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UltiSnips not triggering correctly

I'm using UltiSnips.

http://www.vim.org/scripts/script.php?script_id=2715

Everything works. Let's say when I type st<tab> it inserts submit_tag…. But if st<tab> is in between other characters, it won't work.

For example: foost<tab>bar

Anyway to fix this?

like image 310
Christian Fazzini Avatar asked Nov 30 '22 16:11

Christian Fazzini


1 Answers

I am the author of Ultisnips. You might get faster feedback on our bug tracker for things like this: github.com/SirVer/ultisnips.

The feature you are looking for is called inword expansion. Use it like this:

snippet st "My cool st snippet" w
stollen
endsnippet

The 'w' will make sure your snippet is also expanded inside of other words.

like image 146
SirVer Avatar answered Dec 05 '22 00:12

SirVer