app').If you get an error with TS, make an effort make use of( Vue3Spline, name: "Vue3Spline" ).To determine worldwide parts for Volar type-checking you will need to incorporate:.// components.d.ts.announce element '@vue/ runtime-core' export interface GlobalComponents SplineAnimation: typeof bring in(' vue3-spline') [' Vue3Spline']export {-String.Split-|-}If required rename element to utilize:.app.use( Vue3Spline, label: 'SplineAnimation')// make use of in theme.label string (nonpayment: 'Vue3Spline') - set personalized component name.Alternatively you can easily also import the component regionally.import Vue3Spline coming from 'vue3-spline'.export default elements: Vue3Spline,.,.You can easily after that make use of the component in your theme.
Nuxt 3.This is actually still speculative. Will definitely be actually improved very soon.You can easily mount vue3-spline over yarn or even npm. spline-runtime is a reliance of vue3-spline and also must be actually automatically set up when you put in vue3-spline.If you are using npm:.npm put in vue3-spline@latest-- conserve.If you are actually using yarn:.anecdote add vue3-spline@latest.Make a file gotten in touch with plugins at the root of your task.Create a data called Vue3Spline.client.ts inside the plugins directory.Incorporate the complying with code to the Vue3Spline.client.ts data.import Vue3Spline coming from 'vue3-spline'.export default defineNuxtPlugin(( nuxtApp) => nuxtApp.vueApp.use( Vue3Spline). ).If you receive an inaccuracy with TS, make an effort use( Vue3Spline, label: "Vue3Spline" ).This should register as a worldwide component that you can easily refer to as anywhere in your application under the tag.I would highly recommend making use of a parent tag to make sure that the computer animation simply tons in on the client side.
Github.