Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
html-to-image-puppeteer
Advanced tools
Node.js library to convert HTML to image using Puppeteer.
To install the dependencies, run:
npm install
Usage
Here is an example of how to use the library:
const { convertHtmlToImage } = require('html-to-image-puppeteer');
const htmlContent = '<html><body><h1>Hello, World!</h1></body></html>';
const outputPath = 'output.png';
convertHtmlToImage(htmlContent, outputPath)
.then(() => {
console.log('Image created successfully!');
})
.catch((error) => {
console.error('Error creating image:', error);
});
Scripts
test: Run the tests using Jest.
lint: Lint the code using ESLint.
build: Compile the TypeScript code to JavaScript.
To run a script, use:
For example, to run the tests:
Contributing
Contributions are welcome! Please open an issue or submit a pull request.
Contributors
Subodha Sahu (subodha.sahu-graymatter@monotype.com)
License
This project is licensed under the MIT License. See the LICENSE file for details.
FAQs
Node.js library to convert HTML to image using puppeteer
The npm package html-to-image-puppeteer receives a total of 1 weekly downloads. As such, html-to-image-puppeteer popularity was classified as not popular.
We found that html-to-image-puppeteer demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.