zshot/cliDownload

--wait-for

CLI
--wait-for
Defaultload

Sets when the page is captured.

ValueWhen
loadThe window.load event
readyThe DOMContentLoaded event
networkidle0After the load event, once no request has started or finished for 500ms
networkidle2After the load event, once no request has started or finished for 1 second, with up to two still open
js:NAME_OF_EVENTWhen a CustomEvent of that name fires on window: js:my_event captures once the page runs window.dispatchEvent(new CustomEvent("my_event"))
css:SELECTORWhen a DOM element matching this selector exists on the page
Any numberThat many seconds after DOMContentLoaded: 5, 2.5, or 0 for no delay

Delays

Append seconds to networkidle0 or networkidle2 to wait that much longer once the network is idle: networkidle0:2.5.

Redirects

To capture the destination of a redirect that fires after the page loads, such as a delayed meta-refresh or a timed script redirect, set a number of seconds larger than the redirect delay.

Example

Run locally
zshot --wait-for 5 https://zshot-cli.com/