mirror of
https://github.com/xtr-dev/payload-mailing.git
synced 2025-12-10 08:13:23 +00:00
- Extract sendEmail function to src/sendEmail.ts as primary module - Export BaseEmailData and SendEmailOptions interfaces alongside - Update all imports to use new location - Add sendEmailDefault export for CommonJS compatibility - Export parseAndValidateEmails for external utility use - Updated README to highlight sendEmail as primary export Breaking change: BaseEmailData and SendEmailOptions now imported from main module, not utils/helpers 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
29 lines
915 B
TypeScript
29 lines
915 B
TypeScript
// Main plugin export
|
|
export { mailingPlugin, default as mailingPluginDefault } from './plugin.js'
|
|
|
|
// Types
|
|
export * from './types/index.js'
|
|
|
|
// Services
|
|
export { MailingService } from './services/MailingService.js'
|
|
|
|
// Collections
|
|
export { default as EmailTemplates, createEmailTemplatesCollection } from './collections/EmailTemplates.js'
|
|
export { default as Emails } from './collections/Emails.js'
|
|
|
|
// Jobs (includes the send email task)
|
|
export { mailingJobs, sendEmailJob } from './jobs/index.js'
|
|
export type { SendEmailTaskInput } from './jobs/sendEmailTask.js'
|
|
|
|
// Main email sending function
|
|
export { sendEmail, type BaseEmailData, type SendEmailOptions } from './sendEmail.js'
|
|
export { default as sendEmailDefault } from './sendEmail.js'
|
|
|
|
// Utility functions for developers
|
|
export {
|
|
getMailing,
|
|
renderTemplate,
|
|
processEmails,
|
|
retryFailedEmails,
|
|
parseAndValidateEmails,
|
|
} from './utils/helpers.js' |