12 lines
291 B
JavaScript
12 lines
291 B
JavaScript
import nodemailer from "nodemailer";
|
|
|
|
const transporter = nodemailer.createTransport({
|
|
host: "smtp.example.com",
|
|
port: 587,
|
|
secure: false, // use STARTTLS (upgrade connection to TLS after connecting)
|
|
auth: {
|
|
user: process.env.SMTP_USER,
|
|
pass: process.env.SMTP_PASS,
|
|
},
|
|
});
|