-
I'm using snippy with cmp-snippy. I would like to prepopulate and give default values for my snippets because they are a nice hint. However even when I try stuff like this:
I cannot get clean behavior. Sometimes this works but sometimes it causes more actions to take place and still terminates the snippet expansion state. I also tried
This does something, it prevents backspace from doing anything. It feels like the same behavior I had when I attempted to use the change up above and didnt send anything into cut_text(). I also made sure to remove any remaps for I am under the impression (from past usage of other snippet systems) that default values should be possible to clear out and I can continue to tab through the stops until I'm done editing. For now the workaround involves two methods:
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
I also tried
In hopes of replicating what would happen if i type a letter followed by This is a bit closer but also seems to sometimes terminate the snippet expansion context. |
Beta Was this translation helpful? Give feedback.
-
I have these select mode mappings in my config for so long that I don't remember where I took them from, but all they do is make vim.keymap.set('s', '<BS>', '<c-g>"_c')
vim.keymap.set('s', '<c-h>', '<c-g>"_c')
vim.keymap.set('s', '<Delete>', '<c-g>"_c') I hope they solve it for you too. |
Beta Was this translation helpful? Give feedback.
I have these select mode mappings in my config for so long that I don't remember where I took them from, but all they do is make
<BS>
,<c-h>
and<Delete>
work properly in select mode:I hope they solve it for you too.