All Projects → chromedp → Chromedp

chromedp / Chromedp

Licence: mit
A faster, simpler way to drive browsers supporting the Chrome DevTools Protocol.

Programming Languages

go
31211 projects - #10 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to Chromedp

Pychrome
A Python Package for the Google Chrome Dev Protocol [threading base]
Stars: ✭ 469 (-93.35%)
Mutual labels:  chrome, headless, chrome-devtools
Chrome Devtools Protocol
Chrome Devtools Protocol client for PHP
Stars: ✭ 112 (-98.41%)
Mutual labels:  chrome, headless, chrome-devtools
Go Chrome
A golang library for interacting with the Chrome DevTools Protocol. https://chromedevtools.github.io/devtools-protocol/
Stars: ✭ 96 (-98.64%)
Mutual labels:  chrome, headless, chrome-devtools
Serverless Puppeteer Layers
Serverless Framework + AWS Lambda Layers + Puppeteer = ❤️
Stars: ✭ 247 (-96.5%)
Mutual labels:  chrome, headless
Chromeless
🖥 Chrome automation made simple. Runs locally or headless on AWS Lambda.
Stars: ✭ 13,254 (+87.81%)
Mutual labels:  chrome, headless
Serverless Chrome
🌐 Run headless Chrome/Chromium on AWS Lambda
Stars: ✭ 2,625 (-62.8%)
Mutual labels:  chrome, chrome-debugging-protocol
Phpchrometopdf
A slim PHP wrapper around google-chrome to convert url to pdf or to take screenshots , easy to use and clean OOP interface
Stars: ✭ 127 (-98.2%)
Mutual labels:  chrome, headless
node-headless-chrome
⚠️ 🚧 Install precompiled versions of the Chromium/Chrome headless shell using npm or yarn
Stars: ✭ 20 (-99.72%)
Mutual labels:  chrome-debugging-protocol, headless
Simple Headless Chrome
Simple abstraction to use Chrome as a Headless Browser with Node JS
Stars: ✭ 216 (-96.94%)
Mutual labels:  unit-testing, chrome
Html Pdf Chrome
HTML to PDF converter via Chrome/Chromium
Stars: ✭ 629 (-91.09%)
Mutual labels:  chrome, headless
Lucid
A developer tool for engineers working with React and GraphQL.
Stars: ✭ 397 (-94.37%)
Mutual labels:  chrome, chrome-devtools
Puppetron
Puppeteer (Headless Chrome Node API)-based rendering solution.
Stars: ✭ 429 (-93.92%)
Mutual labels:  chrome, headless
Vscode Chrome Debug
Debug your JavaScript code running in Google Chrome from VS Code.
Stars: ✭ 2,126 (-69.87%)
Mutual labels:  chrome, chrome-debugging-protocol
Nim
Streamline Your Node.js Debugging Workflow with Chromium (Chrome, Edge, More) DevTools.
Stars: ✭ 168 (-97.62%)
Mutual labels:  chrome, chrome-devtools
Cdp4j
cdp4j - Chrome DevTools Protocol for Java
Stars: ✭ 232 (-96.71%)
Mutual labels:  chrome, chrome-devtools
React Rewind
Time Travel Debugger for React useReducer
Stars: ✭ 159 (-97.75%)
Mutual labels:  chrome, chrome-devtools
pythonista-chromeless
Serverless selenium which dynamically execute any given code.
Stars: ✭ 31 (-99.56%)
Mutual labels:  unit-testing, headless
Sms Boom
利用chrome的headless模式,模拟用户注册进行短信轰炸机
Stars: ✭ 507 (-92.82%)
Mutual labels:  chrome, headless
Headlesschrome
A Go package for working with headless Chrome. Run interactive JavaScript commands on web pages with Go and Chrome.
Stars: ✭ 112 (-98.41%)
Mutual labels:  chrome, headless
Chrome Remote Interface
Chrome Debugging Protocol interface for Node.js
Stars: ✭ 3,603 (-48.94%)
Mutual labels:  headless, chrome-debugging-protocol

About chromedp

Package chromedp is a faster, simpler way to drive browsers supporting the Chrome DevTools Protocol in Go without external dependencies.

Unit Tests Go Reference

Installing

Install in the usual Go way:

$ go get -u github.com/chromedp/chromedp

Examples

Refer to the Go reference for the documentation and examples. Additionally, the examples repository contains more examples on complex actions, and other common high-level tasks such as taking full page screenshots.

Frequently Asked Questions

I can't see any Chrome browser window

By default, Chrome is run in headless mode. See DefaultExecAllocatorOptions, and an example to override the default options.

I'm seeing "context canceled" errors

When the connection to the browser is lost, chromedp cancels the context, and it may result in this error. This occurs, for example, if the browser is closed manually, or if the browser process has been killed or otherwise terminated.

Chrome exits as soon as my Go program finishes

On Linux, chromedp is configured to avoid leaking resources by force-killing any started Chrome child processes. If you need to launch a long-running Chrome instance, manually start Chrome and connect using RemoteAllocator.

Executing an action without Run results in "invalid context"

By default, a chromedp context does not have an executor, however one can be specified manually if necessary; see issue #326 for an example.

I can't use an Action with Run because it returns many values

Wrap it with an ActionFunc:

ctx, cancel := chromedp.NewContext()
defer cancel()
chromedp.Run(ctx, chromedp.ActionFunc(func(ctx context.Context) error {
	_, err := domain.SomeAction().Do(ctx)
	return err
}))

I want to use chromedp on a headless environment

The simplest way is to run the Go program that uses chromedp inside the chromedp/headless-shell image. That image contains headless-shell, a smaller headless build of Chrome, which chromedp is able to find out of the box.

Resources

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].