In the email setting of outlook I found that the SMTP host is smtp-mail.outlook.com
so I set my configuration like this.
const transporter = nodemailer.createTransport({
host: "smtp-mail.outlook.com",
port: 587,
auth: {
user: // email,
pass: // app password
}
})