Nuxt
Nuxt renders Vue, and Vue passes unknown elements straight through, so the Vue component works in Nuxt with no changes and no wrapper package.
<script setup lang="ts">const { form } = defineProps<{ form: string }>();</script>
<template> <formbuilder-form :form="form" /></template><template> <ClientOnly> <ContactForm :form="config.public.formId" /> </ClientOnly></template>
<script setup lang="ts">const config = useRuntimeConfig();
useHead({ script: [ { type: 'module', src: 'https://forms.justinjongstra.nl/formbuilder/asset/element.js', }, ], link: [{ rel: 'preconnect', href: 'https://forms.justinjongstra.nl' }],});</script>Silencing the unknown-element warning
Section titled “Silencing the unknown-element warning”Vue logs a warning for tags it does not recognise. Tell it this one is a custom element and the warning goes away:
export default defineNuxtConfig({ vue: { compilerOptions: { isCustomElement: (tag) => tag === 'formbuilder-form', }, },});Cosmetic only: the form renders either way.