Method: QAT::Web::Elements::Collection#finder

Defined in:
lib/qat/web/elements/collection.rb

#finderProc

Returns the collection finder block

Returns:

  • (Proc)

Since:

  • 1.0.0



10
11
12
13
14
15
16
17
18
19
# File 'lib/qat/web/elements/collection.rb', line 10

def finder
  selector = @selector
  proc do
    if selector.last.is_a?(Hash)
      all(*selector[0..1], **selector.last)
    else
      all(*selector)
    end
  end
end