swaf/dist/Mail.d.ts

25 lines
819 B
TypeScript
Raw Normal View History

2020-04-22 15:52:17 +02:00
import { SentMessageInfo } from "nodemailer";
export declare function mailRoute(template: string): string;
export default class Mail {
private static transporter;
private static getTransporter;
static prepare(): Promise<void>;
static end(): void;
static parse(template: string, data: any, textOnly: boolean): string;
private readonly template;
private readonly options;
private readonly data;
constructor(template: MailTemplate, data?: {
[p: string]: any;
});
private verifyData;
send(...to: string[]): Promise<SentMessageInfo[]>;
}
export declare class MailTemplate {
private readonly _template;
private readonly subject;
constructor(template: string, subject: (data: any) => string);
get template(): string;
getSubject(data: any): string;
}