Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/denops_std/function/mod.ts>rubyeval

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

Evaluate Ruby expression {expr} and return its result converted to Vim data structures. Numbers, floats and strings are returned as they are (strings are copied though). Arrays are represented as Vim |List| type. Hashes are represented as Vim |Dictionary| type. Other objects are represented as strings resulted from their "Object#to_s" method. Can also be used as a |method|: GetRubyExpr()->rubyeval() {only available when compiled with the |+ruby| feature}

Parameters

denops: Denops
expr: unknown

Returns

Promise<unknown>