Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

plugins.which-key.settings

Options provided to the require('which-key').setup function.

Type: open submodule of attribute set of lua value

Default: { }

Example:

{
  delay = 200;
  expand = 1;
  notify = false;
  preset = false;
  replace = {
    desc = [
      [
        "<space>"
        "SPACE"
      ]
      [
        "<leader>"
        "SPACE"
      ]
      [
        "<[cC][rR]>"
        "RETURN"
      ]
      [
        "<[tT][aA][bB]>"
        "TAB"
      ]
      [
        "<[bB][sS]>"
        "BACKSPACE"
      ]
    ];
  };
  spec = [
    {
      __unkeyed-1 = "<leader>b";
      group = "Buffers";
      icon = "󰓩 ";
    }
    {
      __unkeyed = "<leader>c";
      group = "Codesnap";
      icon = "󰄄 ";
      mode = "v";
    }
    {
      __unkeyed-1 = "<leader>bs";
      group = "Sort";
      icon = "󰒺 ";
    }
    {
      __unkeyed-1 = [
        {
          __unkeyed-1 = "<leader>f";
          group = "Normal Visual Group";
        }
        {
          __unkeyed-1 = "<leader>f<tab>";
          group = "Normal Visual Group in Group";
        }
      ];
      mode = [
        "n"
        "v"
      ];
    }
    {
      __unkeyed-1 = "<leader>w";
      group = "windows";
      proxy = "<C-w>";
    }
    {
      __unkeyed-1 = "<leader>cS";
      __unkeyed-2 = "<cmd>CodeSnapSave<CR>";
      desc = "Save";
      mode = "v";
    }
    {
      __unkeyed-1 = "<leader>db";
      __unkeyed-2 = {
        __raw = ''
          function()
            require("dap").toggle_breakpoint()
          end
        '';
      };
      desc = "Breakpoint toggle";
      mode = "n";
      silent = true;
    }
  ];
  win = {
    border = "single";
  };
}

Declared by:

plugins.which-key.settings.defer

Start hidden and wait for a key to be pressed before showing the popup.

Only used by enabled xo mapping modes.

Type: null or lua function string

Default: null

Plugin default:

lib.nixvim.mkRaw ''
  function(ctx)
    return ctx.mode == "V" or ctx.mode == "<C-V>
   end''

Declared by:

plugins.which-key.settings.filter

Filter used to exclude mappings

Type: null or lua function string

Default: null

Plugin default:

lib.nixvim.mkRaw ''
  function(mapping)
    return true
  end
''

Declared by: