title: how to send an email with Vuejs?
body: <p>How can I do to send an email with Vuejs2. I manage to get the input data and turned them into json but I can not send them to a mailbox.</p>
  
  <p>I look for the side of PHPMailer but facing PHP and Vue do not mix.</p>
  
  <p>How can I send the form content?</p>
  
  <p><strong>Template :</strong></p>
  
  <pre><code> &lt;div class="JC-contact__form"&gt;
    &lt;b-form @submit="onSubmit" v-if="show"&gt;
  
      &lt;b-form-group class="JC-contact__form--lastName"&gt;
        &lt;b-form-input type="text" v-model="form.lastName"&gt; &lt;/b-form-input&gt;
      &lt;/b-form-group&gt;
  
      &lt;b-form-group class="JC-contact__form--firstName"&gt;
        &lt;b-form-input type="text" v-model="form.firstName"&gt; &lt;/b-form-input&gt;
      &lt;/b-form-group&gt;
  
      &lt;b-form-group&gt;
        &lt;b-form-input type="text" v-model="form.topic"&gt; &lt;/b-form-input&gt;
      &lt;/b-form-group&gt;
      &lt;b-form-group&gt;
        &lt;b-form-input type="email" v-model="form.email"&gt;&lt;/b-form-input&gt;
      &lt;/b-form-group&gt;
  
      &lt;b-form-textarea v-model="form.text"&gt;&lt;/b-form-textarea&gt;
  
      &lt;b-button type="submit"&gt;Envoyer&lt;/b-button&gt;
    &lt;/b-form&gt;
  
  &lt;/div&gt;
  </code></pre>
  
  <p></p>
  
  <p><strong>Script :</strong></p>
  
  <pre><code>  export default {
      name: 'Contact',
      data () {
        return {
          form: {
            lastName: '',
            firstName: '',
            topic: '',
            email: '',
            text: ''
          },
          file: null,
          show: true
        }
      },
      methods: {
        onSubmit (evt) {
          evt.preventDefault();
          alert(JSON.stringify(this.form));
        },
        onReset (evt) {
          evt.preventDefault();
          /* Reset our form values */
          this.form.lastName = '';
          this.form.firstName = '';
          this.form.topic = '';
          this.form.email = '';
          this.form.text = '';
          /* Trick to reset/clear native browser form validation state */
          this.show = false;
          this.$nextTick(() =&gt; {
            this.show = true
          });
        }
      }
    }
  </code></pre>