A react component for determining when it is within a given threshold of the viewport.
This library might not be correct yet, use with care.
npm i react-now-you-see-me
You'll also need React and ReactDOM peer dependencies:
npm i react react-dom.
import React from 'react'import InView from 'react-now-you-see-me'const Foo = props<div><InView = = =>isInViewisInView? <span>I am totally in view right now awesome!</span>: <span>You see me :</span>}</InView></div>