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

x/denops_std/function/mod.ts>histnr

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

The result is the Number of the current entry in {history}. See hist-names for the possible values of {history}. If an error occurred, -1 is returned.

Example:

:let inp_index = histnr("expr")

Can also be used as a method:

GetHistory()->histnr()

Parameters

denops: Denops
history: unknown

Returns

Promise<number>