class Jsrb::NotFastGenerator
Public Class Methods
context()
click to toggle source
# File lib/jsrb/not_fast_generator.rb, line 13 def context @context ||= begin code = Stitch::Package.new(root: "#{source_path}/", dependencies: "#{source_path}/escodegen.browser.js").compile ExecJS.compile(code) end end
source_path()
click to toggle source
# File lib/jsrb/not_fast_generator.rb, line 20 def source_path File.expand_path(File.join(File.dirname(__FILE__), './vendor')) end
Public Instance Methods
call(node)
click to toggle source
# File lib/jsrb/not_fast_generator.rb, line 8 def call(node) self.class.context.call('this.escodegen.generate', node) end