mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-24 05:06:02 +08:00
15 lines
404 B
TypeScript
15 lines
404 B
TypeScript
import EmailTemplates = require('email-templates');
|
|
|
|
const email = new EmailTemplates({
|
|
message: {
|
|
from: 'Test@tesitng.com'
|
|
},
|
|
transport: {
|
|
jsonTransport: true
|
|
}}
|
|
);
|
|
|
|
email.juiceResources('<p>bob</p><style>div{color:red;}</style><div/>');
|
|
email.render('mars/html.pug', {name: 'elon'});
|
|
email.send({template: 'mars', message: {to: 'elon@spacex.com'}, locals: {name: 'Elon'}});
|