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>stdioopen

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

With |--headless| this opens stdin and stdout as a |channel|. May be called only once. See |channel-stdio|. stderr is not handled by this function, see |v:stderr|. Close the stdio handles with |chanclose()|. Use |chansend()| to send data to stdout, and |rpcrequest()| and |rpcnotify()| to communicate over RPC. {opts} is a dictionary with these keys: |on_stdin| : callback invoked when stdin is written to. stdin_buffered : read stdin in |channel-buffered| mode. rpc : If set, |msgpack-rpc| will be used to communicate over stdio Returns:

  • |channel-id| on success (value is always 1)
  • 0 on invalid arguments

Parameters

denops: Denops
opts: unknown

Returns

Promise<unknown>