Skip to main content
Module

x/ddc_vim/deps.ts>autocmd.list

Dark deno-powered completion framework for neovim/Vim
Latest
function autocmd.list
import { autocmd } from "https://deno.land/x/ddc_vim@v4.3.1/deps.ts";
const { list } = autocmd;

List defined autocmds

import { Denops } from "../mod.ts";
import * as autocmd from "./mod.ts";

export async function main(denops: Denops): Promise<void> {
  // List all autocmd
  console.log(await autocmd.list(denops));

  // List all BufEnter autocmd
  console.log(await autocmd.list(denops, "BufEnter"));

  // List all BufEnter autocmd in buffer
  console.log(await autocmd.list(denops, "BufEnter", "<buffer>"));

  // List multiple autocmds
  console.log(await autocmd.list(denops, ["BufEnter", "WinEnter"]));
}

Parameters

denops: Denops
optional
event: "*" | AutocmdEvent | AutocmdEvent[]
optional
pat: string | string[]
optional
options: ListOptions = [UNSUPPORTED]

Returns

Promise<unknown>