[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-4959":3},{"id":4,"name":5,"fullName":6,"owner":5,"repo":5,"description":7,"homepage":8,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":15,"forks30d":15,"starsTrendScore":19,"compositeScore":20,"rankGlobal":9,"rankLanguage":9,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":22,"hasPages":22,"topics":24,"createdAt":9,"pushedAt":9,"updatedAt":32,"readmeContent":33,"aiSummary":34,"trendingCount":15,"starSnapshotCount":15,"syncStatus":35,"lastSyncTime":36,"discoverSource":37},4959,"chromedp","chromedp\u002Fchromedp","A faster, simpler way to drive browsers supporting the Chrome DevTools Protocol.","",null,"Go",13106,876,158,166,0,1,18,83,12,43.83,"MIT License",false,"main",[25,26,27,28,29,30,31],"chrome","chrome-debugging-protocol","chrome-devtools","golang","headless","testing","unit-testing","2026-06-12 02:01:06","# About chromedp\n\nPackage `chromedp` is a faster, simpler way to drive browsers supporting the\n[Chrome DevTools Protocol][devtools-protocol] in Go without external dependencies.\n\n[![Unit Tests][chromedp-ci-status]][chromedp-ci]\n[![Go Reference][goref-chromedp-status]][goref-chromedp]\n[![Releases][release-status]][releases]\n\n## Installing\n\nInstall in the usual Go way:\n\n```sh\n$ go get -u github.com\u002Fchromedp\u002Fchromedp\n```\n\n## Examples\n\nRefer to the [Go reference][goref-chromedp] for the documentation and examples.\nAdditionally, the [examples][chromedp-examples] repository contains more\nexamples on complex actions, and other common high-level tasks such as taking\nfull page screenshots.\n\n## Frequently Asked Questions\n\n> I can't see any Chrome browser window\n\nBy default, Chrome is run in headless mode. See `DefaultExecAllocatorOptions`, and\n[an example][goref-chromedp-exec-allocator] to override the default options.\n\n> I'm seeing \"context canceled\" errors\n\nWhen the connection to the browser is lost, `chromedp` cancels the context, and\nit may result in this error. This occurs, for example, if the browser is closed\nmanually, or if the browser process has been killed or otherwise terminated.\n\n> Chrome exits as soon as my Go program finishes\n\nOn Linux, `chromedp` is configured to avoid leaking resources by force-killing\nany started Chrome child processes. If you need to launch a long-running Chrome\ninstance, manually start Chrome and connect using `RemoteAllocator`.\n\n> Executing an action without `Run` results in \"invalid context\"\n\nBy default, a `chromedp` context does not have an executor, however one can be\nspecified manually if necessary; see [issue #326][github-326]\nfor an example.\n\n> I can't use an `Action` with `Run` because it returns many values\n\nWrap it with an `ActionFunc`:\n\n```go\nctx, cancel := chromedp.NewContext(context.Background())\ndefer cancel()\nchromedp.Run(ctx, chromedp.ActionFunc(func(ctx context.Context) error {\n\t_, err := domain.SomeAction().Do(ctx)\n\treturn err\n}))\n```\n\n> I want to use chromedp on a headless environment\n\nThe simplest way is to run the Go program that uses chromedp inside the\n[chromedp\u002Fheadless-shell][docker-headless-shell] image. That image contains\n`headless-shell`, a smaller headless build of Chrome, which `chromedp` is able\nto find out of the box.\n\n## Resources\n\n* [`headless-shell`][docker-headless-shell] - A build of `headless-shell` that is used for testing `chromedp`\n* [chromedp: A New Way to Drive the Web][gophercon-2017-presentation] - GopherCon SG 2017 talk\n* [Chrome DevTools Protocol][devtools-protocol] - Chrome DevTools Protocol reference\n* [chromedp examples][chromedp-examples] - More complicated examples for `chromedp`\n* [`github.com\u002Fchromedp\u002Fcdproto`][goref-cdproto] - Go reference for the generated Chrome DevTools Protocol API\n* [`github.com\u002Fchromedp\u002Fpdlgen`][chromedp-pdlgen] - tool used to generate `cdproto`\n* [`github.com\u002Fchromedp\u002Fchromedp-proxy`][chromedp-proxy] - a simple CDP proxy for logging CDP clients and browsers\n\n[chromedp-ci]: https:\u002F\u002Fgithub.com\u002Fchromedp\u002Fchromedp\u002Factions\u002Fworkflows\u002Ftest.yml (Test CI)\n[chromedp-ci-status]: https:\u002F\u002Fgithub.com\u002Fchromedp\u002Fchromedp\u002Factions\u002Fworkflows\u002Ftest.yml\u002Fbadge.svg (Test CI)\n[chromedp-examples]: https:\u002F\u002Fgithub.com\u002Fchromedp\u002Fexamples\n[chromedp-pdlgen]: https:\u002F\u002Fgithub.com\u002Fchromedp\u002Fpdlgen\n[chromedp-proxy]: https:\u002F\u002Fgithub.com\u002Fchromedp\u002Fchromedp-proxy\n[devtools-protocol]: https:\u002F\u002Fchromedevtools.github.io\u002Fdevtools-protocol\u002F\n[docker-headless-shell]: https:\u002F\u002Fhub.docker.com\u002Fr\u002Fchromedp\u002Fheadless-shell\u002F\n[github-326]: https:\u002F\u002Fgithub.com\u002Fchromedp\u002Fchromedp\u002Fissues\u002F326\n[gophercon-2017-presentation]: https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=_7pWCg94sKw\n[goref-cdproto]: https:\u002F\u002Fpkg.go.dev\u002Fgithub.com\u002Fchromedp\u002Fcdproto\n[goref-chromedp-exec-allocator]: https:\u002F\u002Fpkg.go.dev\u002Fgithub.com\u002Fchromedp\u002Fchromedp#example-ExecAllocator\n[goref-chromedp]: https:\u002F\u002Fpkg.go.dev\u002Fgithub.com\u002Fchromedp\u002Fchromedp\n[goref-chromedp-status]: https:\u002F\u002Fpkg.go.dev\u002Fbadge\u002Fgithub.com\u002Fchromedp\u002Fchromedp.svg\n[release-status]: https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Fv\u002Frelease\u002Fchromedp\u002Fchromedp?display_name=tag&sort=semver (Latest Release)\n[releases]: https:\u002F\u002Fgithub.com\u002Fchromedp\u002Fchromedp\u002Freleases (Releases)\n","chromedp 是一个用于驱动支持 Chrome DevTools 协议的浏览器的 Go 语言库，无需外部依赖。它通过简洁的 API 提供了网页自动化、测试和截图等核心功能，并且能够以无头模式运行 Chrome 浏览器来提高效率和减少资源消耗。适用于需要进行网页自动化测试、抓取数据或生成页面截图等场景。此外，chromedp 还提供了丰富的示例代码和详细的文档支持，帮助开发者快速上手并解决常见问题。",2,"2026-06-11 03:01:43","top_language"]