Sha256: 3a86b7703eb380192df63b1e3de1501ba18747df152141057836b085f3332cf4
Contents?: true
Size: 803 Bytes
Versions: 188
Compression:
Stored size: 803 Bytes
Contents
require "execjs/version" require "rbconfig" module ExecJS class Error < ::StandardError; end class RuntimeError < Error; end class ProgramError < Error; end class RuntimeUnavailable < RuntimeError; end class << self attr_reader :runtime def runtime=(runtime) raise RuntimeUnavailable, "#{runtime.name} is unavailable on this system" unless runtime.available? @runtime = runtime end def exec(source) runtime.exec(source) end def eval(source) runtime.eval(source) end def compile(source) runtime.compile(source) end def root @root ||= File.expand_path("..", __FILE__) end def windows? @windows ||= RbConfig::CONFIG["host_os"] =~ /mswin|mingw/ end end end
Version data entries
188 entries across 97 versions & 7 rubygems