Syncing viewport from server
See original GitHub issueThis is not a bug, more of a question. I have the following code:
var connectOptions = new ConnectOptions()
{
BrowserWSEndpoint = "ws://..."
};
var browser = await Puppeteer.ConnectAsync(connectOptions);
var pages = await browser.PagesAsync();
foreach (var page in pages)
{
JObject response = await page.Client.SendAsync("Performance.getMetrics");
Console.WriteLine("Response is " + response.ToString());
}
To my surprise, as soon as the command ran, it resized the viewport to the default (800,600). My expectation would be that if a viewport was already set on the server, it shouldn’t modify it. If there is already a viewport set on the server, the PuppeteerSharp state should be synchronized to match it. Thoughts?
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Work with viewports
Viewports are specialized components that enable you to extend your experience without needing to own the parent page in UI Builder. You can...
Read more >Overhaul Productivity: Reduce Wait Times (Project Sharing ...
We're talking about simple line drawings. This becomes a real problem when a viewport is out-of-date (often when 'save viewport cache is turned ......
Read more >Houdini Engine 5.0: SessionSync
The Houdini viewport can be synchronized with other application viewports through the use of HAPI_Viewport, HAPI_GetViewport(), and HAPI_SetViewport().
Read more >How do I keep an MMO synchronized?
It's just a read only game at the moment. My idea is, to tell the server where a player is and how big...
Read more >Solved: Viewport sync and extents - AutoCAD
Solved: Hi all, A strange problem has been plaguing my autocad drawings. On some drawings, if I double click on a viewport it...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@chitoiur you could try to get that using a javascript code and calling
EvaluateFunctionAsync
this was helpful to me, thanks! hopefully this becomes better in the future