mirror of https://github.com/eleith/emailjs.git
build: enable no-undef lint rule in bundle
This commit is contained in:
parent
d3c48660f0
commit
85c381fda3
|
@ -7,7 +7,6 @@ export default {
|
|||
file: 'email.js',
|
||||
format: 'es',
|
||||
sourcemap: true,
|
||||
banner: '/* eslint-disable no-undef */',
|
||||
footer: `
|
||||
/**
|
||||
* @typedef {{ [index: string]: any }} AddressObject
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
import { clearTimeout, setTimeout } from 'timers';
|
||||
|
||||
import { addressparser } from './address.js';
|
||||
import type { MessageAttachment, MessageHeaders } from './message.js';
|
||||
import { Message } from './message.js';
|
||||
|
|
|
@ -1,7 +1,10 @@
|
|||
import { Buffer } from 'buffer';
|
||||
import console from 'console';
|
||||
import { createHmac } from 'crypto';
|
||||
import { EventEmitter } from 'events';
|
||||
import { Socket } from 'net';
|
||||
import { hostname } from 'os';
|
||||
import { setTimeout } from 'timers';
|
||||
import { connect, createSecureContext, TLSSocket } from 'tls';
|
||||
import type { ConnectionOptions } from 'tls';
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
import { Buffer } from 'buffer';
|
||||
import type { PathLike } from 'fs';
|
||||
import {
|
||||
existsSync,
|
||||
|
@ -7,6 +8,7 @@ import {
|
|||
read as readFile,
|
||||
} from 'fs';
|
||||
import { hostname } from 'os';
|
||||
import { nextTick, pid } from 'process';
|
||||
import { Stream } from 'stream';
|
||||
import type { Readable } from 'stream';
|
||||
|
||||
|
@ -117,9 +119,7 @@ function convertDashDelimitedTextToSnakeCase(text: string) {
|
|||
export class Message {
|
||||
public readonly attachments: MessageAttachment[] = [];
|
||||
public readonly header: Partial<MessageHeaders> = {
|
||||
'message-id': `<${new Date().getTime()}.${counter++}.${
|
||||
process.pid
|
||||
}@${hostname()}>`,
|
||||
'message-id': `<${new Date().getTime()}.${counter++}.${pid}@${hostname()}>`,
|
||||
date: getRFC2822Date(),
|
||||
};
|
||||
public readonly content: string = 'text/plain; charset=utf-8';
|
||||
|
@ -741,7 +741,7 @@ class MessageStream extends Stream {
|
|||
};
|
||||
|
||||
this.once('destroy', close);
|
||||
process.nextTick(outputHeader);
|
||||
nextTick(outputHeader);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue