Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Mailer ¶
type Mailer struct {
Sender, Receiver string
Dialer *gomail.Dialer
SubjectLine func(webmention.Mention) string
Body func(webmention.Mention) string
}
Mailer is a webmention.Notifier that -- whenever a mention is received -- sends an email notification from Sender to Receiver, with a subject line produced by SubjectLine and the email body produced by Body.
func NewMailer ¶
Configure a mailer. The SubjectLine and Body properties of the Mailer may be modified to generate custom email subjects and contents, when notifying about Webmentions.
func (Mailer) Receive ¶
func (m Mailer) Receive(mention webmention.Mention)
Receive implements webmention.Notifier
Click to show internal directories.
Click to hide internal directories.