Follow up to #3158
A nicer API
build on top of the CEF API
to make it easier to send/receive messages from DevTools
.
The API
is generated on top of the DevTools
protocol to create a set of model classes to simplify executing DevTools
commands.
The CefSharp.DevTools.DevToolsClient
class is the primary method of accessing the different domains. Each DevTools Domain
has it's own namespace that contains enums
and strongly typed return classes.
Network Domain
is part of the CefSharp.DevTools.Network
namespace. The methods are accessibly though the DevToolsClient
class.
Some basic examples look like (extract from the unit tests)
using (var browser = new ChromiumWebBrowser("www.google.com")) { await browser.WaitForInitialLoadAsync(); using (var devToolsClient = browser.GetDevToolsClient()) { var response = await devToolsClient.Network.SetCookieAsync(name, value, domain: domain, sameSite: sameSite); } } using (var browser = new ChromiumWebBrowser("www.google.com")) { await browser.WaitForInitialLoadAsync(); using (var devToolsClient = browser.GetDevToolsClient()) { var response = await devToolsClient.Browser.GetVersionAsync(); var jsVersion = response.JsVersion; var revision = response.Revision; } }
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4