
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
grunt-email-builder
Advanced tools
Inline css into HTML or inline css into styletags for emails. You can then send files to Litmus for testing.
You can see an example setups below
Install this grunt plugin next to your project's grunt.js gruntfile with: npm install grunt-email-builder
Then add this line to your project's grunt.js
gruntfile:
grunt.loadNpmTasks('grunt-email-builder');
Place this in your grunt file.
emailBuilder: {
test :{
files : {
'dest/ouput.html' : 'src/input.html'
}
}
}
To build your files dynamically
files : [{
expand: true,
src: ['**/*.html'],
dest: 'dest/',
}]
To prevent styles from being inlined, use the data-ignore
attribute on embedded or external styles. Otherwise, all styles will be inlined. External styles with the data-ignore
attribute will be embedded in their own <style>
tag within the src document.
<!-- external styles -->
<link rel="stylesheet" data-ignore="ignore" href="../css/style.css" />
<!-- embedded styles -->
<style data-ignore="ignore">
/* styles here will not be inlined */
</style>
###Options
Can use any of the Juice options along with the ones below
options.emailTest
Type: Object
Send yourself a test email
emailTest : {
// Your Email
email : 'yourEmail@email.com',
// Your email Subject
subject : 'Email Subject',
// Optional
transport: {
type: 'SMTP',
service: 'gmail',
auth: {
user: 'gmail.user@gmail.com',
pass: 'gmailpass'
}
}
}
View nodmailer transport methods if using emailTest.transport option
options.litmus
Type: Object
Send email tests to Litmus
litmus : {
// Optional, defaults to title of email or yyyy-mm-dd if title and options.subject not set
subject : 'Custom subject line',
// Litmus username
username : 'username',
// Litmus password
password : 'password',
// Url to your Litmus account
url : 'https://yoursite.litmus.com',
// Email clients to test for. Find them at http://yoursite.litmus.com/emails/clients.xml
// The <application_code> tags contain the name e.g. Gmail Chrome: <application_code> chromegmailnew </application_code>
applications : ['gmailnew', 'hotmail', 'outlookcom', 'ol2000', 'ol2002', 'ol2003', 'ol2007', 'ol2010','ol2011', 'ol2013', 'appmail6','iphone4', 'iphone5', 'ipad3']
}
options.encodeSpecialChars
Type: Boolean
Default: false
If set to true
, special characters will be encoded to their numerical value. e.g. © --> ©
options.delay
Type: Number
Default: 3500
Set the delay between each test
emailBuilder:{
inline: {
files: { 'dest/output.html' : 'src/input.html' },
options: {
encodeSpecialChars: true
}
},
litmus: {
files: { 'dest/output.html' : 'src/input.html' },
options: {
encodeSpecialChars: true,
litmus: {
username: 'username',
password: 'password',
url: 'https://yoursite.litmus.com',
applications: ['gmailnew', 'ffgmail', 'chromegmail']
}
}
}
}
grunt.registerTask('inline', 'emailBuilder:inline');
grunt.registerTask('litmus', 'emailBuilder:litmus');
If you're having issues with Litmus taking forever to load a test or the title of the test is showing up as "No Subject", it is most likely an issue with the Litmus API. You can check the Litmus status page to find out if their having any issues. If that's not the case, submit an issue and we'll look into further.
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using grunt.
Thanks for helping out:
Juice for compiling.
2.0.2
2.0.1
Copyright (c) 2013 Steven Miller Licensed under the MIT license.
FAQs
Inline css, send email tests, and send Litmus tests
We found that grunt-email-builder demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 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.
Security News
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.