app').If you acquire an error with TS, make an effort use( Vue3Spline, title: "Vue3Spline" ).To describe worldwide elements for Volar type-checking you are going to require to add:.// components.d.ts.proclaim element '@vue/ runtime-core' export interface GlobalComponents SplineAnimation: typeof bring in(' vue3-spline') [' Vue3Spline']export {-String.Split-|-}If needed to have rename part to utilize:.app.use( Vue3Spline, label: 'SplineAnimation')// use in design template.name strand (default: 'Vue3Spline') - set custom-made component label.Conversely you can also import the part regionally.import Vue3Spline from 'vue3-spline'.export default elements: Vue3Spline,.,.You can at that point utilize the part in your design template.
Nuxt 3.This is actually still speculative. Will certainly be upgraded quickly.You can put in vue3-spline over anecdote or npm. spline-runtime is actually a dependence of vue3-spline and also must be actually automatically set up when you put in vue3-spline.If you are using npm:.npm install vue3-spline@latest-- spare.If you are utilizing yarn:.yarn add vue3-spline@latest.Create a folder called plugins at the root of your job.Generate a documents named Vue3Spline.client.ts inside the plugins directory.Add the observing code to the Vue3Spline.client.ts documents.bring in Vue3Spline coming from 'vue3-spline'.export default defineNuxtPlugin(( nuxtApp) => nuxtApp.vueApp.use( Vue3Spline). ).If you obtain an inaccuracy with TS, try usage( Vue3Spline, label: "Vue3Spline" ).This need to enroll as an international part that you can easily name anywhere in your application under the tag.I would certainly encourage making use of a parent tag to make sure that the animation only bunches in on the client edge.
Github.