You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: browsers/viewport.mdx
+5-1Lines changed: 5 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,10 @@ description: "Configure browser viewport size and refresh rate for your automati
5
5
6
6
Kernel browsers allow you to configure the viewport size and refresh rate when creating a browser session. The viewport configuration determines the initial browser window dimensions and display refresh rate. The refresh rate can be explicitly specified or automatically determined based on the width and height if they match a supported configuration.
7
7
8
+
<Note>
9
+
The `refresh_rate` parameter only applies to live view sessions and is ignored for [headless](/browsers/headless) browsers.
10
+
</Note>
11
+
8
12
## Setting viewport configuration
9
13
10
14
You can configure the viewport when creating a browser by specifying the `viewport` parameter with `width` and `height`. The `refresh_rate` is optional and will be automatically determined from the dimensions if they match a supported configuration:
@@ -204,4 +208,4 @@ The server will reject any viewport configuration that doesn't exactly match one
204
208
- Higher resolutions (like 2560x1440) may impact the performance and responsiveness of live view sessions
205
209
- The viewport size affects how websites render, especially those with responsive designs
206
210
- Screenshots taken from the browser will match the configured viewport dimensions
207
-
- In [headless mode](/browsers/headless), the viewport configuration still applies for rendering and screenshots
211
+
- In [headless mode](/browsers/headless), the viewport width and height still apply for rendering and screenshots, but the `refresh_rate` parameter is ignored
0 commit comments