chrome-php / chrome

Instrument headless chrome/chromium instances from PHP
MIT License
2.2k stars 269 forks source link

Page->addPreScript doesn't return identifier #629

Open ethaniel opened 2 weeks ago

ethaniel commented 2 weeks ago

This function calls "Page.addScriptToEvaluateOnNewDocument" which normally returns an identifier, which can later be used to remove the script via "Page.removeScriptToEvaluateOnNewDocument".

However "public function addPreScript" doesn't return this identifier and removePreScript() is missing, so currently there is no way to remove scripts.