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.
An easy way to generate pdf files from ejs templates or html files
#Usage
npm i --save pdf-maker
#For generating pdf from ejs templates
var pdfMaker = require('pdf-maker');
var template = 'path/to/ejsTemplate.ejs';
var data = {
name: 'node.js'
};
var pdfPath = '/path/of/pdf/file.pdf';
var option = {
{
paperSize: {
format: 'A4',
orientation: 'portrait',
border: '1.8cm'
}
};
};
pdfMaker(template, data, pdfPath, option);
Here, 'option' parameter is optional. 'data' is the data which will be used in the ejs template. 'pdfPath' is the path with where the pdf file will be saved.
#For generating pdf from html files.
var pdfMaker = require('pdf-maker');
var template = 'path/to/htmlFile.html';
var pdfPath = '/path/of/pdf/file.pdf';
var option = {
{
paperSize: {
format: 'A4',
orientation: 'portrait',
border: '1.8cm'
}
};
};
pdfMaker(template, pdfPath, option);
#Roadmap
Adding test cases. Removing external dependencies.
FAQs
easy pdf generation using phantom.js
The npm package pdf-maker receives a total of 31 weekly downloads. As such, pdf-maker popularity was classified as not popular.
We found that pdf-maker 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.