رفتن به محتوای اصلی

setWindowSize

Resizes browser window outer size according to provided width and height. Based on your operating system some browser windows might now allow you so have a smaller width than 500px. If you want to mimic the viewport of e.g. an iPhone you should consider using the setViewport command.

Usage
browser.setWindowSize(width, height)
Parameters
NameTypeDetails
widthnumberbrowser will be resized to provided width
heightnumberbrowser will be resized to provided height

Welcome! How can I help?

WebdriverIO AI Copilot