File tree Expand file tree Collapse file tree 1 file changed +17
-4
lines changed Expand file tree Collapse file tree 1 file changed +17
-4
lines changed Original file line number Diff line number Diff line change @@ -746,11 +746,24 @@ more than once). You can escape $ by repeating it.
746746
747747In order to use add something like this to your config :
748748` ` ` vim
749- vnoremap <leader> e " pd :lua require('luasnip.extras.otf').on_the_fly()<cr>
750- nnoremap <leader> e " p :lua require('luasnip.extras.otf').on_the_fly()<cr>
749+ vnoremap <c-f> " ed :lua require('luasnip.extras.otf').on_the_fly()<cr>
750+ inoremap <c-f> < C - \ > <C-O> " e :lua require('luasnip.extras.otf').on_the_fly()<cr>
751751```
752- Notice that you can use your own mapping instead of <leader >e and you can pick another register
753- instead of ` "p `
752+
753+ Notice that you can use your own mapping instead of <c-f > and you can pick another register
754+ instead of ` "p ` . You can even use it several times, as if it where a macro if you add several
755+ mapppings like:
756+ ``` vim
757+ ; For register a
758+ vnoremap <c-f>a "ad:lua require('luasnip.extras.otf').on_the_fly()<cr>
759+ inoremap <c-f>a <C-\><C-O>"a:lua require('luasnip.extras.otf').on_the_fly()<cr>
760+
761+
762+ ; For register b
763+ vnoremap <c-f>b "bd:lua require('luasnip.extras.otf').on_the_fly()<cr>
764+ inoremap <c-f>b <C-\><C-O>"b:lua require('luasnip.extras.otf').on_the_fly()<cr>
765+ ```
766+
754767# LSP-SNIPPETS
755768
756769Luasnip is capable of parsing lsp-style snippets using
You can’t perform that action at this time.
0 commit comments