{"id":21278041,"url":"https://github.com/b13/js-isinviewport","last_synced_at":"2025-07-31T22:16:38.477Z","repository":{"id":25478353,"uuid":"28909126","full_name":"b13/js-isInViewport","owner":"b13","description":null,"archived":false,"fork":false,"pushed_at":"2017-01-23T13:16:15.000Z","size":200,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-03-09T23:38:56.042Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/b13.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-01-07T10:05:50.000Z","updated_at":"2016-05-30T13:43:09.000Z","dependencies_parsed_at":"2022-07-24T06:30:05.388Z","dependency_job_id":null,"html_url":"https://github.com/b13/js-isInViewport","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/b13%2Fjs-isInViewport","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/b13%2Fjs-isInViewport/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/b13%2Fjs-isInViewport/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/b13%2Fjs-isInViewport/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/b13","download_url":"https://codeload.github.com/b13/js-isInViewport/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243738954,"owners_count":20339997,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-11-21T10:09:11.319Z","updated_at":"2025-03-15T13:40:16.796Z","avatar_url":"https://github.com/b13.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"js-isInViewport\n=======\n\nAMD Module to observe items (DOM Elements) the current viewport\n\n\n# Basic usage\n\n```js\n\t\n\tvar _viewport = new isInViewportPlugin({\n\t\n\t\t\t// jQuery selector \n\t\tselector    : '.bJS_isInViewport'\n\n\t\t\t// viewport threshold\n\t\t, threshold : 0\n\t\t\n\t\t\t// scroll and resize timeout\n\t\t, timeout   : 150\n\t\t\n\t\t\t// called after timeout\n\t\t\t// callback is fired after viewport changed (resize) and/or after change\n\t\t, afterChange : function(obj, collection) {\n\t\t\tconsole.log(\"after scroll\");\n\t\t\tconsole.log(obj);\n\t\t\tconsole.log(collection);\n\t\t\tconsole.log(obj.getAllVisibleItemsInViewport());\n\t\t}\n\t});\n```\n\n# Update: search new appended items\n\n```js\n    _viewport.searchNewItems();\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fb13%2Fjs-isinviewport","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fb13%2Fjs-isinviewport","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fb13%2Fjs-isinviewport/lists"}