[Vuejs]-Vue sending email

3👍

Vue is a View (hence the name) library, meant for describing your View layer i.e. how your application looks. Such logic as sending an email would for one be dependent on Javascript itself and not on Vue.

However it is not possible to send an email from Javascript in the browser. Instead you’d need to build a backend which can send an email for you, or you could call the user’s email client, both described here.

3👍

You would ideally send email data (to, message body – html escaped of course) as a request to a backend end point and send from there. You can use Vue’s HTTP resource to send the request: https://github.com/pagekit/vue-resource

But sending an email directly from Vue isn’t possible.

Leave a comment