loktar00 / loktar00/react-lazy-load

"Connected" lazyload loads simultaneously

Open
#173 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
980
Forks
163
PR merge metrics
No merged PRs in 30d

Description

If you have 2 lazyload each one next to the other, when the first one is in viewpost, the second one is loaded automatically.
Example:
```









```

Even if I have the inside a div, when the Component1 is in the viewport, the Component2 is loaded too

Workaround:
If you have some content between each then it loads when it is the viewport

```

Filler content

Some more spacer content

```
Now Conmponent1 is loaded when it's in the viewport, and Component2 is loaded when it's in the viewport

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the issue with two adjacent LazyLoad instances containing Component1 and Component2, then inspect the LazyLoad viewport-detection entry point. Verify that the second component remains unloaded until its own element enters the viewport, including the spacer-content workaround case.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend, performance
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.