Skip to content

Commit

Permalink
docs: add lazy-loading example for lazy.nvim (#30)
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisgrieser committed Oct 7, 2023
1 parent 7c05701 commit 4972a74
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,17 @@ If you prefer to use this plugin only for subword motion, you can disable this f
use { "chrisgrieser/nvim-spider" }

-- lazy.nvim
{ "chrisgrieser/nvim-spider", lazy = true },
{
"chrisgrieser/nvim-spider",
-- example for lazy-loading and keymap
keys = {
{
"e",
function() require("spider").motion("e") end,
mode = { "n", "o", "x" },
},
},
},
```

No keybindings are created by default. Below are the mappings to replace the default `w`, `e`, and `b` motions with this plugin's version of them.
Expand Down

0 comments on commit 4972a74

Please sign in to comment.