Class: Object

Inherits:
BasicObject
Defined in:
lib/v8/tap.rb,
lib/v8/object.rb

Instance Method Summary collapse

Instance Method Details

#eval_js(javascript) ⇒ Object


39
40
41
42
43
# File 'lib/v8/object.rb', line 39

def eval_js(javascript)
  V8::Context.open(:with => self) do |cxt|
    cxt.eval(javascript)
  end
end

#tap {|_self| ... } ⇒ Object

Yields:

  • (_self)

Yield Parameters:

  • _self (Object)

    the object that the method was called on


4
5
6
# File 'lib/v8/tap.rb', line 4

def tap
  yield self
end