9951 explained code solutions for 126 technologies


chrome-headlessHeadless chrome usage example


google-chrome --headless --screenshot="screen.png" -window-size=1280,720 "https://github.com"ctrl + c
--screenshot

make screenshot and save it to specified file

screen.png

path to save screenshot to

--headless

will launch chrome in headless mode

-window-size

set browser window size

1280,720

opens browser in 1280x720 size

github.com

url to open