Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

nuxt-mailer

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nuxt-mailer - npm Package Compare versions

Comparing version 0.10.2 to 0.11.0

2

dist/module.json

@@ -7,3 +7,3 @@ {

},
"version": "0.10.2"
"version": "0.11.0"
}

@@ -12,2 +12,3 @@ import { Transporter } from 'nodemailer';

};
attachments?: [];
};

@@ -23,2 +24,7 @@ interface MailInterface {

html: string;
attachments?: {
filename: string;
path: string;
contentType: string;
}[];
}

@@ -35,3 +41,4 @@ export type SendMailProps = {

customTransporter: (options: TransporterOptions) => Transporter<import("nodemailer/lib/smtp-transport").SentMessageInfo>;
defaultTransporter: Transporter<import("nodemailer/lib/smtp-transport").SentMessageInfo>;
};
export {};
{
"name": "nuxt-mailer",
"version": "0.10.2",
"version": "0.11.0",
"license": "MIT",

@@ -5,0 +5,0 @@ "type": "module",

@@ -418,3 +418,36 @@ # Nuxt Mailer

```
sending attachments Example:
```ts
import { EmailTemplate } from './types/emailTypes'
import { useMailer } from '#mailer'
import { resolvePath } from '@nuxt/kit'
type SendMail = { template: EmailTemplate, to: string, fromEmail: string, fromName: string, subject: string }
export async function sendEmail(request: SendMail) {
const mailService = useMailer()
const filePath = await resolvePath('playground/server/app/email/test.pdf')
return await mailService.sendMail({
requestId: 'test-key',
options: {
fromEmail: request.fromEmail,
fromName: request.fromName,
to: request.to,
subject: request.subject,
text: request.template.text,
html: request.template.html,
attachments: [{
filename: 'file.pdf',
path: filePath,
contentType: 'application/pdf'
}],
}
})
}
```
## Development

@@ -421,0 +454,0 @@

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc