react-lazy-viewport
TypeScript icon, indicating that this package has built-in type declarations

1.0.3 • Public • Published

React Lazy Viewport

PRs Welcome npm version Bundlephobia Bundlephobia

Load your React Component based on viewport, this library using Intersection Observer if your app targeting to not modern browser please adding this Polyfill.

Features

  • [x] Type safe
  • [ ] Preload component
  • [ ] SSR Support

Instalation

$ yarn add react-lazy-viewport
$ npm i react-lazy-viewport

Demo

We assume we have some code like this.
example code
and then if you open the dev tools, the file will be loaded based on viewport example code

Contribute & Help

  • Fork and send Pull Requests are welcome
  • Submit an issues
  • A new feature requests

License

This library is MIT licensed

/react-lazy-viewport/

    Package Sidebar

    Install

    npm i react-lazy-viewport

    Weekly Downloads

    15

    Version

    1.0.3

    License

    MIT

    Unpacked Size

    22 kB

    Total Files

    22

    Last publish

    Collaborators

    • adibfirman