DEV Community

Cover image for I've created React lazy loading component
Maciek Grzybek
Maciek Grzybek

Posted on

1

I've created React lazy loading component

React Laz-Y

Few weeks ago I've built a simple component that utilize React Lazy API and browser Intersection Observer API. In simple words, React Laz-Y allows you to lazy load your component when it appears in the browser's viewport. Thanks to that you don't have to load components that user won't see on the first render, React Laz-y will detect the scroll position for you and inject the correct code when it's actually needed.

Where and how?

You can check it on npm website or on my GitHub account
Usage should be pretty straightforward and everything is explained in the docs.

I hope you'll find this useful 🙂

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more