npm.io
0.1.3 • Published 8 years ago

@lahautesociete/vue-parallax

Licence
MIT
Version
0.1.3
Deps
1
Size
2 kB
Vulns
0
Weekly
0

LHS Vue Parallax

LHS Vue plugin to use lhs-parallax in Vue with a directive.

Installation

npm install @lahautesociete/vue-parallax

Usage

main.js

Import Vue and LhsParallax somewhere in your entry file.
Then tell Vue to use LhsParallax plugin.

import Vue from 'vue';
import LhsVueParallax from '@lahautesociete/vue-parallax'
Vue.use(LhsVueParallax);
CustomComponent.vue

In your vue template, add a HTML element with the v-parallax directive and specify a parallax level.
You can add an optional modifier (x / y) to specify the parallax direction.

<div v-parallax.x="5"></div>