last
The command to get the last Element in a list of Elements.
Last updated
The command to get the last Element in a list of Elements.
Elements.last() -> Elementpy.find("li").last()
---or--- # store in a variable
last = py.xpath("//a").last()
---or--- # chain an Element command
py.get("ul > li").children().last().click()# Errors, 'get' yields Element, not Elements
py.get("ul > li").last()None
Element - The last Element in a list of Elements
IndexError if Elements is empty
Last updated