app').If you receive a mistake along with TS, try usage( Vue3Spline, label: "Vue3Spline" ).To define worldwide parts for Volar type-checking you will definitely need to include:.// components.d.ts.proclaim element '@vue/ runtime-core' export interface GlobalComponents SplineAnimation: typeof bring in(' vue3-spline') [' Vue3Spline']export {-String.Split-|-}If required rename component to make use of:.app.use( Vue3Spline, label: 'SplineAnimation')// usage in theme.name strand (default: 'Vue3Spline') - prepared custom element title.Additionally you can easily also import the part regionally.import Vue3Spline coming from 'vue3-spline'.export nonpayment parts: Vue3Spline,.,.You can then use the element in your template.
Nuxt 3.This is still experimental. Will certainly be actually improved soon.You can easily install vue3-spline over yarn or even npm. spline-runtime is a dependency of vue3-spline and must be actually automatically set up when you set up vue3-spline.If you are making use of npm:.npm put in vue3-spline@latest-- save.If you are actually using yarn:.anecdote include vue3-spline@latest.Create a directory called plugins at the root of your project.Produce a file called Vue3Spline.client.ts inside the plugins directory.Include the adhering to code to the Vue3Spline.client.ts documents.bring in Vue3Spline coming from 'vue3-spline'.export nonpayment defineNuxtPlugin(( nuxtApp) => nuxtApp.vueApp.use( Vue3Spline). ).If you receive an error with TS, attempt make use of( Vue3Spline, name: "Vue3Spline" ).This must sign up as a worldwide element that you can easily call throughout your app under the tag.I will suggest using a moms and dad tag to ensure that the animation merely tons know the customer edge.
Github.