Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const nodemailer = require("nodemailer");
- const transporter = nodemailer.createTransport({
- service: "gmail",
- auth: {
- user: process.env.Username,
- pass: process.env.Password
- }
- });
- const options = {
- from: process.env.Username,
- to: "Email",
- subject: "Verifacation Code",
- html: ""
- };
- transporter.sendMail(options, function(err, info) {
- if (err) {
- console.log(err)
- return;
- }
- console.log("Sent: " + info.response);
- });
Advertisement
Add Comment
Please, Sign In to add comment