in-view.ts 👀
fork by: https://github.com/camwiegert/in-view
Installation
npm install --save in-view-ts
Basic Usage
With in-view-ts, you can register handlers that are called when an element enters or exits the viewport. Each handler receives one element, the one entering or exiting the viewport, as its only argument.
// watch window scrollconst inview = ;inviewregistry ;
// watch parent scrollconst inview = document;inviewregistry ;
// watch parent scrollconst inview = '#parent';inviewregistry ;
API
see: https://github.com/camwiegert/in-view
License MIT