VitePress is a static site generator powered by Vite and Vue, designed for creating documentation websites.
Start collecting data in a matter of clicks.
Let Formspark take care of the servers, databases, and analytics.
Set up any form in seconds.
Out of the box Vue support
Compatible with Jamstack
<!-- .vitepress/theme/components/ContactForm.vue --> <script setup> import { ref } from "vue"; const FORMSPARK_ACTION_URL = "https://submit-form.com/your-form-id"; const message = ref(""); const submitting = ref(false); async function onSubmit() { submitting.value = true; try { await fetch(FORMSPARK_ACTION_URL, { method: "POST", headers: { "Content-Type": "application/json", Accept: "application/json", }, body: JSON.stringify({ message: message.value }), }); message.value = ""; } finally { submitting.value = false; } } </script> <template> <ClientOnly> <form @submit.prevent="onSubmit"> <textarea v-model="message" /> <button type="submit" :disabled="submitting">Send</button> </form> </ClientOnly> </template>