Open bluenike opened 7 years ago
You would have to create 2 separate tansporters, one for plain text and one for html.
Will that allow you to create a multipart message that encapsulates text and html versions of the email in single message?
I fixed this and created a pull request (https://github.com/yads/nodemailer-express-handlebars/pull/13 ). After applying my patch just define the "text_template" and nodemailer will create a multipart/alternative message.
Currently employing a quick hack solution on a production server, somewhere along the lines listed below:
var template_name = 'create_account'
var template_html = require('fs').readFileSync(require('path').join(__dirname, '../templates/emails/' + template_name + '.hbs'), 'utf8')
var template_text = require('striptags')(template_html )
Is it possible to specify a template for the plaintext version of the email (in addition to the html version)?