is-in-viewport
Version:
An ultra-light jQuery plugin that tells you if an element is in the viewport but with a twist.
10 lines (6 loc) • 504 B
Markdown
-----
Run `npm install && npm start` and point your browser to `http://localhost:8000` to see the running example.
The code is bundled using [rollup](https://github.com/rollup/rollup).
You can see how it used in [main.js](./main.js) and see the [bundling config](./rollup.config.js) on how the bundling is done.
Since `is-in-viewport` declares `jquery` as a peer dependency, make sure you have it installed as that is the copy it attaches itself onto.