Method: Watir::Adjacent#child

Defined in:
lib/watir/adjacent.rb

#child(opt = {}) ⇒ Object

Returns element of direct child of current element.

Examples:

browser.form(id: "new_user").child == browser.fieldset
#=> true


94
95
96
# File 'lib/watir/adjacent.rb', line 94

def child(opt = {})
  xpath_adjacent(opt.merge(adjacent: :child, plural: false))
end