Closed Nyoroon closed 6 years ago
Didn't find any CLI options. http://peter.sh/experiments/chromium-command-line-switches/
The only API can do that is Network.setBlockedURLs
, but I am not sure whether it is able to set blocked url to https?://**.jpg
. Even if it can, images without extension can still be loaded.
hm, but selenium is doing that somehow https://stackoverflow.com/a/31581387
You might be able to do that with --user-data-dir
option set and add a Preferences
file in the right directory in user data dir then start chrome.
https://www.chromium.org/administrators/configuring-other-preferences
I think that's how chromedriver do that which applies to selenium.
https://github.com/bayandin/chromedriver/blob/master/chrome_launcher.cc#L804
It's possible to have option to disable loading images when rendering? In original prerender image loading was disabled https://github.com/prerender/prerender/blob/c3a83d6ba001cac6e2dc22cacab6b7d510835e36/lib/server.js#L72 It's controlled by chrome headless CLI options or doable via api?