title: Line breaks are ignored when render text in html template
body: <p>I am developing a website where a user with an specific role can log in and send an email to a mailing list. I am working with Flask, Python and using Mailgun to deliver the emails. I am using an HTML template and the email text is passed as a parameter from the view function to the send email function. The problem is that the email text is delivered ignoring the line breaks. If the email text is:</p>
  
  <pre><code>Line 1
  Line 2
  Line 3
  </code></pre>
  
  <p>It will be delivered as:</p>
  
  <pre><code>Line 1 Line 2 Line 3
  </code></pre>
  
  <p>My view function is:</p>
  
  <pre><code>@main.route('/send-email-to-mailinglist', methods=['POST', 'GET'])
  def send_email_to_mailinglist():
      form = MailToMailingList()
      if form.validate_on_submit():
          form.subject = form.subject.data
          form.email_text = form.email_text.data
          send_email('mailing_list@mydomain.com', 
                      form.subject, 'auth/email/to_mailing_list', 
                      description = "now",
                      sender='info', text = form.email_text)
          return redirect(url_for('.index'))
      return render_template ('send_email_to_all.html', form=form)
  </code></pre>
  
  <p>My send email function is:</p>
  
  <pre><code>def send_email(to, subject, template, **kwargs):  
      app = current_app._get_current_object()
      auth = ('api', app.config['MAILGUN_API_KEY'])
      url = 'https://api.mailgun.net/v3/{}/messages'.format(app.config['MAILGUN_DOMAIN']) 
      data = {
          'from': '&lt;{}@{}&gt;'.format(kwargs['sender'],app.config['MAILGUN_DOMAIN']),
          'to': to,
          'subject': subject,    
          'text': render_template(template + '.txt', **kwargs),
          'html': render_template(template + '.html', **kwargs)
      }
      response = requests.post(url, auth=auth, data=data)
      response.raise_for_status()
  </code></pre>
  
  <p>And the relevant part of the HTML template is:</p>
  
  <pre><code>&lt;!doctype html&gt;
  &lt;html&gt;
    &lt;head&gt;
      &lt;meta name="viewport" content="width=device-width"&gt;
      &lt;meta http-equiv="Content-Type" content="text/html; charset=UTF-8"&gt;
      &lt;style&gt;
      &lt;/style&gt;
    &lt;/head&gt;
    &lt;body&gt;
  ..
  ..
      &lt;p&gt; {{ text }} &lt;/p&gt;
  ..
  ..
    &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>