Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does resend.emails.send() auto converts React components to HTML and text, or should I additionally use render()? #444

Closed
GorvGoyl opened this issue Nov 1, 2024 · 2 comments

Comments

@GorvGoyl
Copy link

GorvGoyl commented Nov 1, 2024

Is it enough to use the react property, or do I need to explicitly include html and text properties?

await resend.emails.send({
  from: 'Acme <[email protected]>',
  to: ['[email protected]'],
  subject: 'hello world',
  react: EmailTemplate(),
});

await resend.emails.send({
  from: 'Acme <[email protected]>',
  to: ['[email protected]'],
  subject: 'hello world',
  react: EmailTemplate(),
  html: EmailTemplateinHTML(),
  text: EmailTemplateinText(),
});
@bukinoshita
Copy link
Member

The react attribute only generates the HTML. We should definitely implement this in the SDK

@vcapretz
Copy link
Member

closing as duplicate of #369, we will work on it 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants