Skip to content

Commit

Permalink
chore: export type MailDataRequired (#1053)
Browse files Browse the repository at this point in the history
  • Loading branch information
childish-sambino authored Mar 5, 2020
1 parent 7f2d4dd commit e29d125
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
3 changes: 3 additions & 0 deletions packages/helpers/classes/mail.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,9 @@ export interface MailData {
hideWarnings?: boolean,
}

export type MailDataRequired = MailData & (
{ text: string } | { html: string } | { templateId: string } | { content: MailContent[] & { 0: MailContent } });

export interface MailJSON {
from: EmailJSON;
subject: string;
Expand Down
5 changes: 1 addition & 4 deletions packages/mail/src/mail.d.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
import {ClientResponse} from "@sendgrid/client/src/response";
import {ResponseError} from "@sendgrid/helpers/classes";
import {MailContent, MailData} from "@sendgrid/helpers/classes/mail";

type MailDataRequired = MailData & (
{ text: string } | { html: string } | { content: MailContent[] & { 0: MailContent } });
import {MailDataRequired} from "@sendgrid/helpers/classes/mail";

declare class MailService {
/**
Expand Down

0 comments on commit e29d125

Please sign in to comment.