app').If you obtain an error with TS, try use( Vue3Spline, title: "Vue3Spline" ).To describe global components for Volar type-checking you are going to require to incorporate:.// components.d.ts.announce component '@vue/ runtime-core' export user interface GlobalComponents SplineAnimation: typeof bring in(' vue3-spline') [' Vue3Spline']export {-String.Split-|-}If needed rename part to make use of:.app.use( Vue3Spline, label: 'SplineAnimation')// make use of in layout.title cord (nonpayment: 'Vue3Spline') - established customized element name.As an alternative you may also import the element locally.import Vue3Spline coming from 'vue3-spline'.export default parts: Vue3Spline,.,.You can at that point make use of the element in your layout.
Nuxt 3.This is still speculative. Will be upgraded soon.You can put in vue3-spline over yarn or npm. spline-runtime is an addiction of vue3-spline and should be instantly put in when you put in vue3-spline.If you are actually making use of npm:.npm install vue3-spline@latest-- save.If you are actually using anecdote:.anecdote incorporate vue3-spline@latest.Make a directory called plugins at the root of your venture.Create a report named Vue3Spline.client.ts inside the plugins directory.Incorporate the observing code to the Vue3Spline.client.ts data.bring in Vue3Spline from 'vue3-spline'.export default defineNuxtPlugin(( nuxtApp) => nuxtApp.vueApp.use( Vue3Spline). ).If you obtain a mistake with TS, attempt make use of( Vue3Spline, name: "Vue3Spline" ).This need to enroll as a global part that you can easily refer to as anywhere in your app under the tag.I will recommend utilizing a parent tag to guarantee that the animation only lots in on the customer edge.
Github.