Tombarr / vue-wheel

Wheel directive on Vue

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

vue-wheel

wheel directive for vuejs 2.0

Just use native event handlers like:

<template>
  <ul v-on:wheel="onWheel">
    <li></li>
  </ul>
</template>

Installation

NPM (recommended)

npm install vuewheel --save

Standalone

Simple download from releases and include it in script tag.

Get started

import Vue from 'vue'
import vuewheel from 'vuewheel'

Vue.use(vuewheel)

Directive v-wheel then can be used in any of your Component.

<template>
  <ul v-wheel="onWheel">
    <li></li>
  </ul>
</template>
...

Method onWheel receives the native event,

  • e - event

LICENSE

MIT

About

Wheel directive on Vue

License:MIT License


Languages

Language:JavaScript 100.0%