No description or website provided.
Branch: master
Clone or download
Latest commit 1867986 May 18, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
dist refactor May 18, 2018
example refactor May 18, 2018
src refactor May 18, 2018
.editorconfig Support vuejs 2.x Dec 29, 2016
.eslintrc
.gitignore
CHANGELOG.md
LICENSE Support vuejs 2.x Dec 29, 2016
README.md refactor May 18, 2018
package-lock.json 3.3.4 May 18, 2018
package.json 3.3.4 May 18, 2018
webpack.base.js refactor May 18, 2018
webpack.config.js 3.3.2 Mar 9, 2018
webpack.example.config.js refactor May 18, 2018

README.md

vue-sticky

A directive to sticky element for vue.js(2.x).

for useage with Vue 1.x, see the 2.x branch

Install

npm install vue-sticky --save

Dev

run npm install and npm run dev

Import

import VueSticky from 'vue-sticky' // Es6 module

const VueSticky = VueSticky.default // Global variable

Use

directives: {
  'sticky': VueSticky,
},
<ELEMENT v-sticky="{ zIndex: NUMBER, stickyTop: NUMBER, disabled: [true|false]}">
  <div> <!-- sticky wrapper, IMPORTANT -->
    CONTENT
  </div>
</ELEMENT>