tatut / clj-chrome-devtools

Clojure API for controlling a Chrome DevTools remote
MIT License
130 stars 21 forks source link

[Feature Request] Some missing functionality compared with Puppeteer #28

Open lucywang000 opened 4 years ago

lucywang000 commented 4 years ago

I have been using puppeteer and always wondered to have something like this project in clj world, so thanks a lot!

When I try to port of my project from puppeteer to clj-chrome-devtools, there are essentially several missing pieces that are blocking me:

  1. When connected to a browser, clj-chrome-devtools always use of the first page listed in the CDP websocket endpoint.
  2. Some handy features are missing, e.g. page.title(), page.url() etc.
  3. Querying by XPATH seems not supported, only css selectors are allowed.

Does it make sense to add these supports to this project? If so I may try to contribute to it.

tatut commented 4 years ago

Yes, the higher level automation API is a good place for utilities.

I'll happily accept PR's, when adding utilities please follow the same style as the already existing ones.

And when changing connection behaviour, add them behind an option key.