{"action":"created","issue":{"url":"https://api.github.com/repos/callmecavs/layzr.js/issues/32","labels_url":"https://api.github.com/repos/callmecavs/layzr.js/issues/32/labels{/name}","comments_url":"https://api.github.com/repos/callmecavs/layzr.js/issues/32/comments","events_url":"https://api.github.com/repos/callmecavs/layzr.js/issues/32/events","html_url":"https://github.com/callmecavs/layzr.js/pull/32","id":78679271,"number":32,"title":"Unbind events when all elements are shown","user":{"login":"mauriciosoares","id":2321259,"avatar_url":"https://avatars.githubusercontent.com/u/2321259?v=3","gravatar_id":"","url":"https://api.github.com/users/mauriciosoares","html_url":"https://github.com/mauriciosoares","followers_url":"https://api.github.com/users/mauriciosoares/followers","following_url":"https://api.github.com/users/mauriciosoares/following{/other_user}","gists_url":"https://api.github.com/users/mauriciosoares/gists{/gist_id}","starred_url":"https://api.github.com/users/mauriciosoares/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mauriciosoares/subscriptions","organizations_url":"https://api.github.com/users/mauriciosoares/orgs","repos_url":"https://api.github.com/users/mauriciosoares/repos","events_url":"https://api.github.com/users/mauriciosoares/events{/privacy}","received_events_url":"https://api.github.com/users/mauriciosoares/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-05-20T20:14:50Z","updated_at":"2015-07-16T14:55:01Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/callmecavs/layzr.js/pulls/32","html_url":"https://github.com/callmecavs/layzr.js/pull/32","diff_url":"https://github.com/callmecavs/layzr.js/pull/32.diff","patch_url":"https://github.com/callmecavs/layzr.js/pull/32.patch"},"body":"When all images were already being shown for the user, the `window` object still had the listeners for `scroll` and `resize`.\r\n\r\nI made a little trick to unbind these events, since they get useless after all elements are shown."},"comment":{"url":"https://api.github.com/repos/callmecavs/layzr.js/issues/comments/121980388","html_url":"https://github.com/callmecavs/layzr.js/pull/32#issuecomment-121980388","issue_url":"https://api.github.com/repos/callmecavs/layzr.js/issues/32","id":121980388,"user":{"login":"callmecavs","id":2293641,"avatar_url":"https://avatars.githubusercontent.com/u/2293641?v=3","gravatar_id":"","url":"https://api.github.com/users/callmecavs","html_url":"https://github.com/callmecavs","followers_url":"https://api.github.com/users/callmecavs/followers","following_url":"https://api.github.com/users/callmecavs/following{/other_user}","gists_url":"https://api.github.com/users/callmecavs/gists{/gist_id}","starred_url":"https://api.github.com/users/callmecavs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/callmecavs/subscriptions","organizations_url":"https://api.github.com/users/callmecavs/orgs","repos_url":"https://api.github.com/users/callmecavs/repos","events_url":"https://api.github.com/users/callmecavs/events{/privacy}","received_events_url":"https://api.github.com/users/callmecavs/received_events","type":"User","site_admin":false},"created_at":"2015-07-16T14:55:01Z","updated_at":"2015-07-16T14:55:01Z","body":"@v1vendi @mauriciosoares I think the resolution here is to fix the `_destroy` method, but _not_ automatically call it when all images are loaded.  because the scroll/resize events are debounced, with no images to check, they add hardly any weight to the page\r\n\r\nin regards to people dynamically adding images - `updateSelector` was what I intended to address that.  I apologize for the lack of documentation surrounding it, but thats definitely the method you'd want to call while adding images."}}