Skip to content

Instantly share code, notes, and snippets.

View llldc21's full-sized avatar

Lucas Lima de Castro Fernandes llldc21

View GitHub Profile
@DiegoPinho
DiegoPinho / nodemailer.js
Created February 6, 2018 16:31
Enviando e-mail usando Node.js
'use strict';
const nodemailer = require('nodemailer');
// Generate test SMTP service account from ethereal.email
// Only needed if you don't have a real mail account for testing
nodemailer.createTestAccount((err, account) => {
// create reusable transporter object using the default SMTP transport
let transporter = nodemailer.createTransport({
host: 'smtp.ethereal.email',