Emulation.setVisibleSizeResizes the frame/viewport of the page. Note that this does not affect the frame's container (e.g. browser window). Can be used to produce screenshots of the specified size. Not supported on Android.
| Name | Type | Description |
|---|---|---|
width | integer | Frame width (DIP). |
height | integer | Frame height (DIP). |
{
"id": 1,
"method": "Emulation.setVisibleSize",
"params": {
"width": 1280,
"height": 720
}
}
{
"id": 1,
"result": {}
}
const result = await send('Emulation.setVisibleSize', {"width": 1280, "height": 720});
console.log(result);