{"repo":"sindresorhus/capture-website","free":true,"listed":false,"github":"https://github.com/sindresorhus/capture-website","clone":"git clone https://github.com/sindresorhus/capture-website.git","description":"Capture screenshots of websites","language":"JavaScript","stars":2013,"topics":["capture-screenshots","screenshots","website-screenshot-capturer","website-screenshot","puppeteer","nodejs","npm-package"],"license":"MIT","category":"scrapers-browser-automation","readme_excerpt":"capture-website Capture screenshots of websites It uses Puppeteer (Chrome) under the hood. See capture-website-cli for the command-line tool. Install Note to Linux users: If you get a sandbox-related error, you need to enable system sandboxing. Usage API captureWebsite.file(input, outputFilePath, options?) Capture a screenshot of the given input and save it to the given outputFilePath . Intermediate directories are created for you if they do not exist. Returns a Promise that resolves when the screenshot is written. captureWebsite.buffer(input, options?) Capture a screenshot of the given input . Returns a Promise with the screenshot as binary. captureWebsite.base64(input, options?) Capture a screenshot of the given input . Returns a Promise with the screenshot as Base64. input Type: string The URL, file URL, data URL, local file path to the website, or HTML. options Type: object inputType Type: string \\ Default: 'url' \\ Values: 'url' 'html' Set it to html to treat input as HTML content. width Type: number \\ Default: 1280 Page width. height Type: number \\ Default: 800 Page height. type Type: string \\ Values: 'png' 'jpeg' 'webp' 'pdf' \\ Default: 'png' Output type. [!NOTE] When using 'pdf' , the clip , element , and quality options are not supported. Use the pdf option for PDF-specific settings. quality Type: number \\ Values: 0...1 \\ Default: 1 Image quality. Only for {type: 'jpeg'} and {type: 'webp'} . scaleFactor Type: number \\ Default: 2 Scale the webpage n times. The default ","default_branch":null,"files":null,"tree":[],"storefront":"/r/sindresorhus","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/sindresorhus/capture-website/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}