-
Notifications
You must be signed in to change notification settings - Fork 11
Feature to add "reply_to" option when sending mails. #58
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
Merged
Merged
Changes from 6 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
6950754
types: Add reply_to field to CommonMail type
aolamide 708a864
adapters: Add reply_to handling in adaptMail and implement adaptReply…
aolamide 16325b9
tests: Update adapter tests to account for various cases of replyTo
aolamide 7e6376f
examples: Updated email example to show use of the reply_to field
aolamide 5ee1633
tests: Add tests for adaptReplyToRecipient function to validate recip…
aolamide 89a26f0
style: Linting fixes
aolamide 089b7f5
examples: Add replyTo field to nodemailer transport example
aolamide File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,7 @@ import { MailtrapClient } from "mailtrap" | |
const TOKEN = "<YOUR-TOKEN-HERE>"; | ||
const SENDER_EMAIL = "<[email protected]>"; | ||
const RECIPIENT_EMAIL = "<[email protected]>"; | ||
const REPLY_TO_EMAIL = "<[email protected]>"; | ||
|
||
const client = new MailtrapClient({ token: TOKEN }); | ||
|
||
|
@@ -28,6 +29,7 @@ client | |
from: { name: "Mailtrap Test", email: SENDER_EMAIL }, | ||
to: [{ email: RECIPIENT_EMAIL }], | ||
subject: "Hello from Mailtrap!", | ||
reply_to: { email: REPLY_TO_EMAIL }, | ||
html: ` | ||
<!doctype html> | ||
<html> | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.