npm install --save vue3-smooth-scroll import { createApp } from 'vue' import VueSmoothScroll from 'vue3-smooth-scroll' const app = createApp(...) app.use(VueSmoothScroll) CDN: <body> <script src="https://unpkg.
Smooth, non-blocking animation usingrequestAnimationFrame(with fallback) Y-axis or vertical scrolling Specific scroll containers 1.4kB gzipped, 3.1kB min import{createApp}from'vue'importVueSmoothScrollfrom'vue3-smooth-scroll'constapp=createApp(...)app.use(VueSmoothScroll) ...
npm install vue3-smooth-scrollbar#yarn add vue3-smooth-scrollbar Usage App.vue <template> <scrollbar><!--content--></scrollbar> </template>importScrollbarfrom"vue3-smooth-scrollbar";exportdefault{components:{ Navbar, Scrollbar },}; Add to your styles...
scrollTop = position); }; step(); container === window ? container.scrollTo(0, position) : (container.scrollTop = position) } step() } const VueSmoothScroll = { install(app, config) { install (app, config) { const isOldVersion = !app.version.startsWith('3') app.directive('...
Using Vue3 with VueCLI. Followed all the steps of installation, and ran into an issue when I get to this: const app = createApp(...) app.use(VueSmoothScroll) Other than imports, these are the only two lines in main.js, and the console re...
Smooth, non-blocking animation usingrequestAnimationFrame(with fallback) Y-axis or vertical scrolling Specific scroll containers 1.4kB gzipped, 3.1kB min Installation npm: npm install --save vue3-smooth-scroll import{createApp}from'vue'importVueSmoothScrollfrom'vue3-smooth-scroll'constapp=createApp...