@sendgrid/helpers
Version:
Twilio SendGrid NodeJS internal helpers
24 lines (18 loc) • 412 B
TypeScript
export type EmailData = string|{ name?: string; email: string; }
export type EmailJSON = { name?: string; email: string }
export default class EmailAddress {
constructor(data?: EmailData);
/**
* From data
*/
fromData(data: EmailData): void;
/**
* Set name
*/
setName(name: string): void;
/**
* Set email (mandatory)
*/
setEmail(email: string): void;
toJSON(): EmailJSON;
}