Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
dark-mode-screenshot
Advanced tools
This Puppeteer script takes a screenshot of a webpage in Light and Dark Mode.
This Puppeteer script takes a screenshot of a webpage in Light and Dark Mode.
Dark Mode | Light Mode |
---|---|
screenshot-dark.png
|
screenshot-light.png
|
Locally from the command line:
$ node dark-mode-screenshot.js --url https://googlechromelabs.github.io/dark-mode-toggle/demo/ --output screenshot --fullPage --pause 750
Without installing remotely from npm:
$ npx dark-mode-screenshot --url https://googlechromelabs.github.io/dark-mode-toggle/demo/ --output screenshot --fullPage --pause 750
Parameter (long) | Parameter (short) | Description |
---|---|---|
--url | -u | The URL of the webpage, defaults to https://googlechromelabs.github.io/dark-mode-toggle/ demo/index.html . |
--output | -o | The file prefix of the screenshot (there will be a light and a dark file), defaults to screenshot . |
--fullPage | -f | Whether or not to take a full page screenshot, defaults to true . |
--pause | -p | Time in milliseconds to pause before taking each screenshot, defaults to 0 . |
Thanks to @mathiasbynens for implementing
page.emulateMediaFeatures(features)
in Puppeteer and for making this script a lot lighter.
Apache 2.0
FAQs
This Puppeteer script takes a screenshot of a webpage in Light and Dark Mode.
The npm package dark-mode-screenshot receives a total of 3 weekly downloads. As such, dark-mode-screenshot popularity was classified as not popular.
We found that dark-mode-screenshot demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.