https://github.com/hrmeetsingh/chromeremotedebugrepl
REPL for Chrome browser debugging using Chrome DevTools Protocol
https://github.com/hrmeetsingh/chromeremotedebugrepl
Last synced: 5 months ago
JSON representation
REPL for Chrome browser debugging using Chrome DevTools Protocol
- Host: GitHub
- URL: https://github.com/hrmeetsingh/chromeremotedebugrepl
- Owner: hrmeetsingh
- License: mit
- Created: 2019-08-11T12:52:47.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2024-11-27T01:44:51.000Z (6 months ago)
- Last Synced: 2024-11-27T02:29:41.929Z (6 months ago)
- Language: JavaScript
- Size: 39.1 KB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ChromeRemoteDebugREPL
REPL for Chrome browser debugging using Chrome DevTools Protocol
## Running chrome in debug mode
Prerequisite to using the module is a chrome instance running in debug mode
#### For Linux (tested on Ubuntu 16.04)
`#sudo google-chrome --remote-debugging-port=`
#### For MacOS
`sudo /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --remote-debugging-port=`
## Starting the REPL
**Clone the repo -** `git clone https://github.com/hrmeetsingh/ChromeRemoteDebugREPL.git`
`cd ChromeRemoteDebugREPL`
After starting chrome with debuging flag, run the following command to start chrome devtools API
**Installing dependencies -** `yarn install`
**Starting the REPL -** `yarn start`
## Getting list of running browsers and attaching remote interface
**Getting list of browsers -** `ChromeRemoteDebugREPL:REPL> .list `
**Attaching remote interface to an instance -** `ChromeRemoteDebugREPL:REPL> .attach `
**Getting list of open pages and tabs -** `ChromeRemoteDebugREPL:REPL> pages`
**Getting hold of chrome devtools wrapper -** `ChromeRemoteDebugREPL:REPL> client`
### TODO
This is the bare minimum functionality and can be used for basic debugging of chrome browser. Needs more work on the endless possibilities the CDP offers.