vue-touch-card-dl

vue directive for animating components

Usage no npm install needed!

<script type="module">
  import vueTouchCardDl from 'https://cdn.skypack.dev/vue-touch-card-dl';
</script>

README

vue-touch-card-dl

GitHub npm npm

vue-touch-card-dl is a vue directive used to animating cards.

live example: https://codepen.io/JOSEJUAN/pen/QWbvzoV

Install

npm install --save vue-touch-card-dl

Installation

in your main.js

import Vue from 'vue';
import myDirective from 'vue-touch-card-dl';

Vue.directive('touch-card', myDirective);

you can choose the directive's name.

<div id="app">
    <h1>mouseover this card</h1>
    <div v-touch-card="15" class="card"></div>
</div>

Directive's value

    <div v-touch-card="15" class="card"></div>

NOTE: 15 is the directive's value and represent degrees of rotating.