Skip to main content
Module

x/denops_std/function/mod.ts>appendbufline

📚 Standard module for denops.vim
Go to Latest
function appendbufline
import { appendbufline } from "https://deno.land/x/denops_std@v4.1.3/function/mod.ts";

Like |append()| but append the text in buffer {buf}. This function works only for loaded buffers. First call |bufload()| if needed. For the use of {buf}, see |bufname()|. {lnum} is the line number to append below. Note that using |line()| would use the current buffer, not the one appending to. Use "$" to append at the end of the buffer. Other string values are not supported. On success 0 is returned, on failure 1 is returned. In |Vim9| script an error is given for an invalid {lnum}. If {buf} is not a valid buffer or {lnum} is not valid, an error message is given. Example: :let failed = appendbufline(13, 0, "# THE START") Can also be used as a |method| after a List, the base is passed as the second argument: mylist->appendbufline(buf, lnum)

Parameters

denops: Denops
buf: unknown
lnum: unknown
text: unknown

Returns

Promise<unknown>