I am trying to send a email through my server so anyone will enter his/her email to my app instantly get an welcome email i'm using nodemailer but i'm getting error in my console click the link to see the error and please explain what does this error means? enter image description here
let transporter = nodemialer.createTransport({
service : 'gmail',
auth: {
user: 'gauravrajpoot452@gmail.com',
pass: 'sonu@12345'
}
});
app.post('/', (req, res) => {
let email = req.body.userEmail;
let mailOptions = {
from: 'gauravrajpoot452@gmail.com',
to: email,
subject: 'Node tutorials',
text: `Hey gaurav you're a software engineer.`
}
transporter.sendMail(mailOptions, (error, info) => {
if(error){
console.log(error);
}
else{
console.log('Email sent' + info.response);
}
});
});