{"id":21602016,"url":"https://github.com/ger86/use-observer-hook","last_synced_at":"2026-03-02T03:32:17.791Z","repository":{"id":39325519,"uuid":"220012361","full_name":"ger86/use-observer-hook","owner":"ger86","description":"Repository to show the use of the custom hook useObserver that integrates the API Intersection Observer with React.","archived":false,"fork":false,"pushed_at":"2023-01-06T02:15:42.000Z","size":4019,"stargazers_count":4,"open_issues_count":20,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-11T21:45:15.353Z","etag":null,"topics":["intersection-observer","javascript","react","react-hook","react-hooks","reactjs"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ger86.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-11-06T14:12:35.000Z","updated_at":"2024-08-20T20:47:45.000Z","dependencies_parsed_at":"2023-02-05T02:46:07.275Z","dependency_job_id":null,"html_url":"https://github.com/ger86/use-observer-hook","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ger86/use-observer-hook","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ger86%2Fuse-observer-hook","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ger86%2Fuse-observer-hook/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ger86%2Fuse-observer-hook/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ger86%2Fuse-observer-hook/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ger86","download_url":"https://codeload.github.com/ger86/use-observer-hook/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ger86%2Fuse-observer-hook/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29991770,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-02T01:47:34.672Z","status":"online","status_checked_at":"2026-03-02T02:00:07.342Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["intersection-observer","javascript","react","react-hook","react-hooks","reactjs"],"created_at":"2024-11-24T19:11:44.867Z","updated_at":"2026-03-02T03:32:17.768Z","avatar_url":"https://github.com/ger86.png","language":"JavaScript","readme":"# 👀 useObserver hook\n\n## Description\n\nProject to show how we can integrate the **API Intersection Observer** with React creating a custom hook that allows us to reuse it as many times as we want.\n\nWhat we will do is take advantage of the API Intersection Observer to load our images in a lazy way as we scroll down. We will integrate this functionality into the hook `useObserver` to use it wherever we need it.\n\n## Hooks used\n\n- `useEffect`\n- `useState`\n- `useRef`\n\n## To Read More\n\n[Intersection Observer API](https://developer.mozilla.org/es/docs/Web/API/Intersection_Observer_API)\n\n[Javascript. Intersection Observer](https://medium.com/@ger86/javascript-intersection-observer-1410b743c991)\n\n[React. Intersection Observer hook](https://medium.com/@ger86/react-intersection-observer-hook-e57209493ce2)\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fger86%2Fuse-observer-hook","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fger86%2Fuse-observer-hook","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fger86%2Fuse-observer-hook/lists"}