Skip to content

mc-fdc-dev/chrome-rs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

chrome-rs

chromiumのdevtools protocol向けの低レベルAPIラッパー

Sample code

use chrome_rs::{Browser, Page};

#[tokio::main]
async fn main() {
    let browser = Browser::new("http://localhost:9222".to_string());
    let page = browser.new_page("https://www.google.com").await.unwrap();
    let mut page_client = Page::new(page.websocket_debugger_url);
    page_client.connect().await.unwrap();
    let data = page_client.screenshot().await.unwrap();
    std::fs::write("screenshot.png", data).unwrap();
    browser.close_page(&page.id).await.unwrap();
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages