Send email templates with Nodemailer + EJS
How to send an email template with Nodemailer + EJS
Prerequisite:
- Nodejs (Installed)
Before running any of the following steps. Make sure you run npm install
to install any dependencies needed for this project.
npm i nodemailer ejs path dotenv
Create a file named .env
, and copy everything inside the .env-example
file to the .env
file. Inside the .env file, fill in the information with your email and password.
Once you have successfully completed the above steps. Run npm start
to send an email