Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/denops_std/function/nvim/mod.ts>nvim_set_keymap

📚 Standard module for denops.vim
Go to Latest
function nvim_set_keymap
import { nvim_set_keymap } from "https://deno.land/x/denops_std@v3.6.0/function/nvim/mod.ts";

Sets a global |mapping| for the given mode. To set a buffer-local mapping, use |nvim_buf_set_keymap()|. Unlike |:map|, leading/trailing whitespace is accepted as part of the {lhs} or {rhs}. Empty {rhs} is ||. |keycodes| are replaced as usual. Example: call nvim_set_keymap('n', ' ', '', {'nowait': v:true}) is equivalent to: nmap <Nop Parameters: ~ {mode} Mode short-name (map command prefix: "n", "i", "v", "x", …) or "!" for |:map!|, or empty string for |:map|. {lhs} Left-hand-side |{lhs}| of the mapping. {rhs} Right-hand-side |{rhs}| of the mapping. {opts} Optional parameters map. Accepts all |:map-arguments| as keys excluding || but including |noremap|. Values are Booleans. Unknown key is an error.

Parameters

denops: Denops
mode: unknown
lhs: unknown
rhs: unknown
opts: unknown

Returns

Promise<unknown>