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

Add possibility to attach/embed templates #13

Closed
wneessen opened this issue Jun 1, 2022 · 0 comments
Closed

Add possibility to attach/embed templates #13

wneessen opened this issue Jun 1, 2022 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@wneessen
Copy link
Owner

wneessen commented Jun 1, 2022

I occasionally check the go-mail/mail issue tracker if people run into problems, that we might want to address in wneessen/go-mail. I stumbled upon go-mail/mail#74 and thought it would be a good idea to implement a simple way to attach/embed template.Template to Msg objects.

@wneessen wneessen self-assigned this Jun 1, 2022
@wneessen wneessen added the enhancement New feature or request label Jun 1, 2022
wneessen added a commit that referenced this issue Jun 1, 2022
Implemented the AttachTemplate and EmbedTemplate methods.
Test coverage and documentation is still to be done
wneessen added a commit that referenced this issue Jun 3, 2022
- Switched the previous implementation to support text/template as well as html/template
- Added SetBody*Template() methods to use a template directly as message body
- Added AddAlternative*Template() methods to use a template directly as alternative message part
wneessen added a commit that referenced this issue Jun 3, 2022
wneessen added a commit that referenced this issue Jun 3, 2022
wneessen added a commit that referenced this issue Jun 3, 2022
wneessen added a commit that referenced this issue Jun 3, 2022
SonarQube identified two code smells for duplicate string usage
@wneessen wneessen closed this as completed Jun 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant