Skip to content

yuda-lyu/w-email

Repository files navigation

w-email

A wrapper nodemailer for email.

language npm version license gzip file size npm download npm download jsdelivr download

Documentation

To view documentation or get support, visit docs.

Installation

Using npm(ES6 module):

Note: w-email is mainly dependent on nodemailer.

npm i w-email

Example:

Link: [dev source code]

import WEmail from 'w-email'

//opt
let opt = {
    srcName: 'test name',
    srcEmail: 'your email',
    srcPW: 'your password',
    emTitle: 'test title',
    emContent: '<h4>test head</h4>'+'<div>test content</div>',
    toEmails: 'to email',
    //toEmailsCC: 'to email',
    //toEmailsBCC: 'to email',
    emAttachments: {
        filename: 'your filename',
        path: 'your filepath'
    }
}

//WEmail
new WEmail(opt)
    .then((msg)=>{
        console.log('then',msg)
    })
    .catch((err)=>{
        console.log('catch',err)
    })

About

A wrapper nodemailer for email.

Resources

License

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published