Module: Watir::HTML::Util

Defined in:
lib/watir-webdriver/html/util.rb

Class Method Summary collapse

Class Method Details

.classify(name) ⇒ Object



7
8
9
10
11
12
13
# File 'lib/watir-webdriver/html/util.rb', line 7

def classify(name)
  if name =~ /^HTML(.+)Element$/
    $1
  else
    name
  end
end

.paramify(str) ⇒ Object



15
16
17
# File 'lib/watir-webdriver/html/util.rb', line 15

def paramify(str)
  classify(str).snake_case
end