Registry / utility / execjs

execjs

JSON →
library2.10.1rbrubygemsunverified

ExecJS lets you run JavaScript code from Ruby.

gem install execjs
INSTALL
IMPORT
SIG · EXECJS
E
execjs
utilityrubyv2.10.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

ExecJS
✓ require 'execjs'

Run JavaScript code from Ruby

require 'execjs' context = ExecJS.compile('function add(a, b) { return a + b; }') context.call('add', 1, 2) # => 3
Debug
Known issues
gotchaRequires a JavaScript runtime (e.g., Node.js, therubyracer) to be installed
fix
Install Node.js or add therubyracer to your Gemfile
affects: >= 0
Upgrade
Version history
2.10.1latest on RubyGems
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
execjs — gem install execjs · libregistry