Sleep

Vue- ssr-carousel - Performant Carousel Component

.A performance focused Vue slide carousel made for SSR/SSG environments. No JS is used to design the carousel or even it is actually slides. The target is actually to strengthen LCP and also CLS credit ratings given that there is no layout or even profit improvements when JS hydates. It's mainly developed for rendering "card" style slides (like for linking to articles or even items) where the carousel-ness is actually conditionally used based on the lot of cards that are actually slotted in as well as the viewport width.Take a look at the demo: https://vue-ssr-carousel.netlify.app.Mount.yarn incorporate vue-ssr-carousel.Default.import SsrCarousel coming from 'vue-ssr-carousel'.bring in ssrCarouselCss from 'vue-ssr-carousel/index. css'.Vue.component 'ssr-carousel', SsrCarousel.Nuxt.// nuxt.config.js.export nonpayment buildModules: [' vue-ssr-carousel/nuxt']Consumption.Slide 1.Slide 2.Slide 3.For additional instances, view the demonstration: https://vue-ssr-carousel.netlify.app.Tips.If your slides are generated along with v-for, utilize vital market values that are actually based upon the records you are actually knotting with. In short, do v-for=" slide in slides": trick=' slide.id' instead that v-for=" slide, mark in slides": key=' index'.Don't make use of v-if on the root factor of slide elements.API.Props.Slots.Slots.Summary.default.Where your slides obtain infused.back-arrow.Change the default back image. Port props:.impaired - Real if at first page when not looping.next-arrow.Change the default upcoming icon. Slot props:.disabled - Correct if finally webpage when not knotting.dot.Change the default pagination dots. Port props:.index - The web page index that the dot represents.impaired - Real if dot represents current web page.Strategies.Strategies.Description.next().Move forward a page or slide, depending on the paginate-by-slide prop.back().Return a page or slide, depending upon the paginate-by-slide uphold.goto( mark).Go to an index. If paginate-by-slide is misleading, this equates to a webpage countered. If accurate, this equates to a slide countered.Occasions.See https://vue-ssr-carousel.netlify.app/events.Celebrations.Summary.change( mark ).Axed when the inner index counter improvements.input.Like adjustment however aimed for usage with v-model.push.Fired on mouse or even touch down.release.Shot on mouse or even repair.burden: start.Shot on begin of dragging.bother: end.Shot on end of tugging.tween: beginning( mark ).Discharged when the carousel begins tweening to it is actually final setting.tween: edge( mark ).Terminated when the carousel has finished tweening to it's location.