Open nontakran123 opened 1 year ago
@nontakran123 I added the following to a file in plugins directory
import Vue3TouchEvents from 'vue3-touch-events';
export default defineNuxtPlugin((nuxtApp) => {
nuxtApp.vueApp.use(Vue3TouchEvents)
});
and the following to my component
<div
v-touch:swipe.left="()=>swipe('next')"
v-touch:swipe.right="() =>swipe('prev')"
>
and it's working ok.
Hi. I am trying to import this plugin into my Nuxt 3 project which is typescript. I have tried following the guide. which it cannot run Is there a detailed usage guideline or not? Thank you.