Skip to content

Instantly share code, notes, and snippets.

View DevDuck's full-sized avatar

Rich Chung DevDuck

  • Erithmitic
  • Seattle, WA
View GitHub Profile
@DevDuck
DevDuck / EmailTools.ts
Last active April 24, 2024 14:30
Generate EML file format from an Office Outlook email
import { Buffer } from "buffer";
var item: Office.MessageRead;
Office.onReady(() => {
item = Office.context.mailbox.item;
});
/**
* Gets the email in EML format (IMF text file). This function executes the following steps:
* (1) item.getAllInternetHeadersAsync()