Skip to content

Files

Latest commit

7804d85 · Jun 12, 2024

History

History

compare-chromedp

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Aug 27, 2022
Aug 27, 2022
Nov 14, 2022
Jun 12, 2024
Nov 16, 2022
Aug 27, 2022
Aug 27, 2022
Mar 6, 2024
Aug 27, 2022
Nov 14, 2022
Mar 6, 2024
Aug 27, 2022
Jun 12, 2024
Aug 27, 2022
Mar 6, 2024
Aug 27, 2022
Jun 12, 2024
Mar 6, 2024
Nov 14, 2022

Rod comparison with chromedp

chromedp is one of the most popular drivers for Devtools Protocol.

To help developers who are familiar with chromedp to understand rod better we created side by side examples between rod and chromedp.

To run an example:

  1. clone rod
  2. cd to the folder of an example, such as cd lib/examples/compare-chromedp/click
  3. run go run .
rod chromedp Description
click click use a selector to click on an element
cookie cookie set a HTTP cookie on requests
download_file download_file do headless file downloads
download_image download_image do headless image downloads
emulate emulate emulate a specific device such as an iPhone
eval eval evaluate javascript and retrieve the result
headers headers set a HTTP header on requests
keys keys send key events to an element
logic logic more complex logic beyond simple actions
pdf pdf capture a pdf of a page
proxy proxy authenticate a proxy server which requires authentication
remote remote connect to an existing DevTools instance using a remote WebSocket URL
screenshot screenshot take a screenshot of a specific element and of the entire browser viewport
submit submit fill out and submit a form
subtree subtree populate and travel a subtree of the DOM
text text extract text from a specific element
upload upload upload a file on a form
visible visible wait until an element is visible

Occasionally, some of these examples may break if the specific websites these examples use get updated. We suggest you create an issue.