sitespeedio / browsertime

Measure and Optimize Web Performance

Home Page:https://www.sitespeed.io/documentation/browsertime/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add more options for identifying iframe

zzhao2010 opened this issue · comments

Hi,
as per documentation, switch.toFrame(id) can be done by id ONLY.. What if a scenario where the iframe doesn’t contain id attribute like the snapshot attached? How do I switch to this iframe? I think it is a pretty common use case. So I wanted to request a feature enrichment for iframe specifically such that there are more options that users can choose to identify iframe component with Sitespeed.io out of box without having selenium involved. Thanks.
image

I added a PR where you can use xpath or css selecors.

Awesome! Thank you.