# Svelte

Svelte (opens new window) is a web framework that compiles an app at build step. The EmailJS SDK will make it very easy to send emails with Svelte.

Below is simple contact form component, ContactUs.svelte:

  import emailjs from '@emailjs/browser';

  const sendEmail = (e) => {
      .sendForm('YOUR_SERVICE_ID', 'YOUR_TEMPLATE_ID', e.target, {
        publicKey: 'YOUR_PUBLIC_KEY',
        () => {
        (error) => {
          console.log('FAILED...', error.text);

<form on:submit|preventDefault={sendEmail}>
  <input type="text" name="user_name">
  <input type="email" name="user_email">
  <textarea name="message"></textarea>
  <input type="submit" value="Send">