Versions in this module Expand all Collapse all v0 v0.3.1 Jul 14, 2022 Changes in this version + type Logger interface + Logf func(format string, args ...interface{}) + type Option func(s *Sender) + func Auth(smtpUserName, smtpPasswd string) Option + func Charset(charset string) Option + func ContentType(contentType string) Option + func Log(l Logger) Option + func Port(port int) Option + func SMTP(smtp SMTPClient) Option + func STARTTLS(enabled bool) Option + func TLS(enabled bool) Option + func TimeOut(timeOut time.Duration) Option + type Params struct + Attachments []string + From string + InReplyTo string + InlineImages []string + Subject string + To []string + UnsubscribeLink string + type SMTPClient interface + Auth func(auth smtp.Auth) error + Close func() error + Data func() (io.WriteCloser, error) + Mail func(from string) error + Quit func() error + Rcpt func(to string) error + type Sender struct + func NewSender(smtpHost string, options ...Option) *Sender + func (em *Sender) Send(text string, params Params) error + func (em *Sender) String() string