# How to register the snippetKeymap ?

**URL:** https://discuss.codemirror.net/t/how-to-register-the-snippetkeymap/8107
**Category:** v6
**Created:** [April 10, 2024, 9:48am UTC](https://discuss.codemirror.net/t/how-to-register-the-snippetkeymap/8107 "2024-04-10T09:48:06Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![stof](https://discuss.codemirror.net/user_avatar/discuss.codemirror.net/stof/32/4332_2.png) [@stof](https://discuss.codemirror.net/u/stof)
#### Post date: [April 10, 2024, 9:48am UTC](https://discuss.codemirror.net/t/how-to-register-the-snippetkeymap/8107/1 "2024-04-10T09:48:06Z")

</div>

Most exported keymaps in core packages have a type `readonly KeyBinding[]` which can be used in `keymap.of()`.  
However, `snippetKeymap` in `@codemirror/autocomplete` has the type `Facet<readonly KeyBinding[], readonly KeyBinding[]>`. How is the `snippetKeymap` meant to be used ? I haven’t found any examples using it (or using snippets for that matter) and the reference manual is not clear about how to use it either.

How is this expected to be used ?

---

<div class="post-metadata">

### Author: ![marijn](https://discuss.codemirror.net/user_avatar/discuss.codemirror.net/marijn/32/136_2.png) [@marijn](https://discuss.codemirror.net/u/marijn)
#### Post date: [April 10, 2024, 10:49am UTC](https://discuss.codemirror.net/t/how-to-register-the-snippetkeymap/8107/2 "2024-04-10T10:49:43Z")

</div>

This is not a keymap, but a way to replace the default keybindings associated with snippets. But its docs already tell you this.
