Skip to content

Instantly share code, notes, and snippets.

@JaiParakh
Last active June 16, 2019 05:51
Show Gist options
  • Save JaiParakh/ad2c48b7a1065c67b79c8b96105d1992 to your computer and use it in GitHub Desktop.
Save JaiParakh/ad2c48b7a1065c67b79c8b96105d1992 to your computer and use it in GitHub Desktop.
/*
All the index.js code from first article
*/
function getAuth(auth){
var Mail = require('./createMail.js');
var obj = new Mail(auth, "receiver's gmail Id", 'Subject', 'Body', 'mail');
//'mail' is the task, if not passed it will save the message as draft.
//attachmentSrc array is optional.
obj.makeBody();
//This will send the mail to the recipent.
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment