Skip to main content
Module

x/ddc_vim/deps.ts>fn.remote_expr

Dark deno-powered completion framework for neovim/Vim8
Go to Latest
function fn.remote_expr
import { fn } from "https://deno.land/x/ddc_vim@v2.3.0/deps.ts";
const { remote_expr } = fn;

Send the {string} to {server}. The string is sent as an expression and the result is returned after evaluation. The result must be a String or a |List|. A |List| is turned into a String by joining the items with a line break in between (not at the end), like with join(expr, "\n"). If {idvar} is present and not empty, it is taken as the name of a variable and a {serverid} for later use with |remote_read()| is stored there. If {timeout} is given the read times out after this many seconds. Otherwise a timeout of 600 seconds is used. See also |clientserver| |RemoteReply|. This function is not available in the |sandbox|. {only available when compiled with the |+clientserver| feature} Note: Any errors will cause a local error message to be issued and the result will be the empty string. Variables will be evaluated in the global namespace, independent of a function currently being active. Except when in debug mode, then local function variables and arguments can be evaluated. Examples: :echo remote_expr("gvim", "2+2") :echo remote_expr("gvim1", "b:current_syntax") Can also be used as a |method|: ServerName()->remote_expr(expr)

Parameters

denops: Denops
server: unknown
string: unknown
optional
idvar: unknown
optional
timeout: unknown

Returns

Promise<unknown>