# \[kak-lsp\] going through snippet placeholders

**URL:** <https://discuss.kakoune.com/t/kak-lsp-going-through-snippet-placeholders/2417>\
**Category:** Help\
**Created:** [March 4, 2024, 2:00am UTC](https://discuss.kakoune.com/t/kak-lsp-going-through-snippet-placeholders/2417 "2024-03-04T02:00:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![oktoling](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/oktoling/32/1441_2.png) [@oktoling](https://discuss.kakoune.com/u/oktoling)\
**Post date:** [March 4, 2024, 2:00am UTC](https://discuss.kakoune.com/t/kak-lsp-going-through-snippet-placeholders/2417/1 "2024-03-04T02:00:41Z")

</div>

![image](https://discuss.kakoune.com/uploads/default/original/2X/6/6e17df41ad07ae9dcafe5baf87c868e369fbae83.png)  
Hi guys! I’m liking kakoune/kak-lsp so far!  
sometimes when i use autocomplete i get these snippets that come with placeholders, which are likely generated .  
how do i use these? so far ive just been ignoring them and manually insert whats in these placeholders.  
also escaping back to normal mode removes them.

i know that [`phantom-selection`](https://github.com/occivink/kakoune-phantom-selection?tab=readme-ov-file) exists (haven’t installed it yet) but if i were to do this manually what keys should i use?

---

<div class="post-metadata">

**Author:** ![arrufat](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/arrufat/32/1157_2.png) [@arrufat](https://discuss.kakoune.com/u/arrufat)\
**Post date:** [March 4, 2024, 6:45am UTC](https://discuss.kakoune.com/t/kak-lsp-going-through-snippet-placeholders/2417/2 "2024-03-04T06:45:06Z")

</div>

Once you have selected the snipped with `c-p` or `c-n`, just keep typing and you will replace the first placeholder.

Then you need to add this:

```kak
map global insert <tab> '<a-;>:try lsp-snippets-select-next-placeholders catch %{ execute-keys -with-hooks <lt>tab> }<ret>' -docstring 'Select next snippet placeholder'

```

To be able to press `tab` to jump to the next placeholder.

You can read more about this here: [GitHub - kakoune-lsp/kakoune-lsp: Kakoune Language Server Protocol Client](https://github.com/kakoune-lsp/kakoune-lsp?tab=readme-ov-file#configure-mappings)

---

<div class="post-metadata">

**Author:** ![oktoling](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/oktoling/32/1441_2.png) [@oktoling](https://discuss.kakoune.com/u/oktoling)\
**Post date:** [March 4, 2024, 11:40am UTC](https://discuss.kakoune.com/t/kak-lsp-going-through-snippet-placeholders/2417/3 "2024-03-04T11:40:57Z")

</div>

this works! thanks!
