I am using friendly-snippets to provider snippets for luasnip, following the repository. But I don't know how to config the neovim so that it works well for snippets with choice list, e.g.,
"set font size": {
"prefix": "fontsize",
"body": "${1|\\Huge,\\huge,\\LARGE,\\Large,\\large,\\normalsize,\\small,\\footnotesize,\\scriptsize,\\tiny|}",
"description": "Select a font size"
},
When I type fontsize and <CR>, the choice list doesn't show up and it is always the first choice, i.e., \Huge typed.
I have tried to add the codes here to my configuration.This time when I type fontsize and <CR>, the choice list pops up, as shown here:
But I can't do anything from now on.
I thought we should add some keymap to handle this event, so I tried to read the documentation of luasnip but found it is lengthy and mainly on the snippets defined in the lua way, rather defined in a json file. So I am wondering is it possible to fix this problem based on the beloved configuration I have followed so far here?
I am using
friendly-snippets
to provider snippets forluasnip
, following the repository. But I don't know how to config the neovim so that it works well for snippets with choice list, e.g.,When I type
But I can't do anything from now on.
I thought we should add some keymap to handle this event, so I tried to read the documentation of
fontsize
and<CR>
, the choice list doesn't show up and it is always the first choice, i.e.,\Huge
typed. I have tried to add the codes here to my configuration.This time when I typefontsize
and<CR>
, the choice list pops up, as shown here:luasnip
but found it is lengthy and mainly on the snippets defined in thelua
way, rather defined in ajson
file. So I am wondering is it possible to fix this problem based on the beloved configuration I have followed so far here?