1.0.2 • Published 5 years ago

webux-mailer v1.0.2

Weekly downloads
-
License
SEE LICENSE IN li...
Repository
github
Last release
5 years ago

Webux Mailer

This module is a wrapper to send mails, it uses nodemailer.

Installation

npm i --save webux-mailer

Usage

const webuxMailer = require("webux-mailer");
const express = require("express");
const app = express();

const options = {
  isEnabled: true,
  host: process.env.HOST || "",
  port: 465,
  useSSL: true,
  user: process.env.USER || "",
  password: process.env.PASSWORD || ""
};

webuxMailer.init(options, app);

webuxMailer
  .mail(
    "sender@mail.com",
    "recipient@mail.com",
    "Hello world",
    "Hello World",
    "<b>Hello World ! </b>"
  )
  .then(sent => {
    console.log(sent);
  })
  .catch(err => {
    console.error(err);
  });

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

SEE LICENSE IN license.txt

1.0.2

5 years ago