WebPagetest Forums

Full Version: Waiting for a element to become visible
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
We have a few HTML games in which we need to measure the loading time. The game loads many of the assets asynchronously and so the regular document load events captured by WPT might not be helpful.

Is it possible to measure the time till a certain button becomes visible in the page. Selenium typically has methods available to wait for visibility of an element, but I don't see similar options in WPT scripting language.
Do you want execution to wait until the element has loaded or do you just need to know timings? I haven't tried it yet, but maybe you can execute some js to poll for the element?
If you just need the timings you can use the custom metrics option or instrument it so it shows up with user timings.
Reference URL's