app').If you receive an error with TS, make an effort make use of( Vue3Spline, name: "Vue3Spline" ).To determine global parts for Volar type-checking you will need to have to incorporate:.// components.d.ts.proclaim module '@vue/ runtime-core' export interface GlobalComponents SplineAnimation: typeof bring in(' vue3-spline') [' Vue3Spline']export {-String.Split-|-}If needed rename element to use:.app.use( Vue3Spline, name: 'SplineAnimation')// use in layout.title strand (default: 'Vue3Spline') - established custom-made component label.As an alternative you may additionally import the element in your area.import Vue3Spline from 'vue3-spline'.export default elements: Vue3Spline,.,.You can after that utilize the element in your layout.
Nuxt 3.This is still experimental. Will definitely be improved very soon.You can easily put up vue3-spline over anecdote or even npm. spline-runtime is actually an addiction of vue3-spline and also ought to be automatically mounted when you set up vue3-spline.If you are actually using npm:.npm mount vue3-spline@latest-- save.If you are actually utilizing yarn:.yarn incorporate vue3-spline@latest.Make a directory phoned plugins at the root of your project.Create a data called Vue3Spline.client.ts inside the plugins directory site.Incorporate 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 acquire an error with TS, try make use of( Vue3Spline, name: "Vue3Spline" ).This should register as a global component that you can call anywhere in your app under the tag.I will advise using a moms and dad tag to make sure that the animation merely tons in on the customer side.
Github.