Skip to main content
Deno 2 is finally here ๐ŸŽ‰๏ธ
Learn more
Module

x/denops_std/function/vim/mod.ts>getcharstr

๐Ÿ“š Standard module for denops.vim
Go to Latest
function getcharstr
import { getcharstr } from "https://deno.land/x/denops_std@v3.6.0/function/vim/mod.ts";

Get a single character from the user or input stream as a string. If [expr] is omitted, wait until a character is available. If [expr] is 0 or false, only get a character when one is available. Return an empty string otherwise. If [expr] is 1 or true, only check if a character is available, it is not consumed. Return an empty string if no character is available. Otherwise this works like |getchar()|, except that a number result is converted to a string.

Parameters

denops: Denops
optional
expr: unknown

Returns

Promise<unknown>