Sleep

Vue- ssr-carousel - Performant Carousel Element

.A functionality focused Vue carousel made for SSR/SSG settings. No JS is actually used to format the slide carousel or it's slides. The objective is to enhance LCP and CLS scores because there is no layout or markup changes when JS hydates. It's primarily designed for providing "memory card" type slides (like for linking to articles or products) where the carousel-ness is conditionally applied based upon the number of cards that are actually slotted in along with the viewport width.Look at the demonstration: https://vue-ssr-carousel.netlify.app.Install.yarn include vue-ssr-carousel.Default.bring in SsrCarousel coming from 'vue-ssr-carousel'.import ssrCarouselCss coming from 'vue-ssr-carousel/index. css'.Vue.component 'ssr-carousel', SsrCarousel.Nuxt.// nuxt.config.js.export default buildModules: [' vue-ssr-carousel/nuxt']Usage.Slide 1.Slide 2.Slide 3.For additional examples, view the demonstration: https://vue-ssr-carousel.netlify.app.Tips.If your slides are actually produced along with v-for, utilize key values that are based upon the data you are actually looping with. In short, perform v-for=" slide in slides": trick=' slide.id' instead that v-for=" slide, mark in slides": key=' index'.Do not use v-if on the root component of slide elements.API.Props.Ports.Slots.Description.nonpayment.Where your slides obtain infused.back-arrow.Change the nonpayment back icon. Slot props:.disabled - Accurate if initially page when not knotting.next-arrow.Switch out the nonpayment next image. Port props:.disabled - True if finally webpage when certainly not looping.dot.Change the nonpayment pagination dots. Slot props:.index - The web page mark that the dot embodies.handicapped - Correct if dot exemplifies existing page.Methods.Techniques.Explanation.upcoming().Move forward a page or even slide, relying on the paginate-by-slide prop.back().Return a page or even slide, relying on the paginate-by-slide uphold.goto( index).Visit an index. If paginate-by-slide is actually incorrect, this relates to a web page offset. If correct, this translates to a slide countered.Celebrations.View https://vue-ssr-carousel.netlify.app/events.Celebrations.Description.adjustment( index ).Shot when the internal index counter improvements.input.Same as modification but planned for use along with v-model.push.Shot on computer mouse or contact down.release.Fired on computer mouse or patch up.nuisance: start.Shot on begin of yanking.pain: end.Shot on end of moving.tween: start( mark ).Fired when the carousel starts tweening to it is actually ultimate setting.tween: end( mark ).Shot when the carousel has finished tweening to it is actually location.