Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lazy loading 需要注意的地方 #17

Open
Lauviah0622 opened this issue Aug 8, 2020 · 0 comments
Open

lazy loading 需要注意的地方 #17

Lauviah0622 opened this issue Aug 8, 2020 · 0 comments
Labels
未完成 做事啊小孬孬 筆記 有東西就記下來

Comments

@Lauviah0622
Copy link
Owner

  1. scroll event ,這樣就要加上 throttle
    然後計算位置

  2. intersectionObserver,這個比較方便,

要調整 rootMargin, threshhold,
https://www.coderbridge.com/@Nick0603/9fca97bba1774fa29a9ae76473cfab36

https://medium.com/@mingjunlu/lazy-loading-images-via-the-intersection-observer-api-72da50a884b7

https://mropengate.blogspot.com/2017/12/dom-debounce-throttle.html

@Lauviah0622 Lauviah0622 added 筆記 有東西就記下來 未完成 做事啊小孬孬 labels Aug 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
未完成 做事啊小孬孬 筆記 有東西就記下來
Projects
None yet
Development

No branches or pull requests

1 participant