{"id":21565146,"url":"https://github.com/cfware/add-event-listener","last_synced_at":"2025-06-14T03:05:23.356Z","repository":{"id":57101014,"uuid":"177225798","full_name":"cfware/add-event-listener","owner":"cfware","description":"Calls owner.addEventListener and returns a function to remove the listener","archived":false,"fork":false,"pushed_at":"2023-10-15T15:10:55.000Z","size":31,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-14T03:03:30.870Z","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":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cfware.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-23T00:30:09.000Z","updated_at":"2022-08-13T03:20:21.000Z","dependencies_parsed_at":"2025-01-24T11:43:59.606Z","dependency_job_id":"0b0f60b3-29eb-492d-a045-56c1933dec03","html_url":"https://github.com/cfware/add-event-listener","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/cfware/add-event-listener","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cfware%2Fadd-event-listener","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cfware%2Fadd-event-listener/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cfware%2Fadd-event-listener/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cfware%2Fadd-event-listener/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cfware","download_url":"https://codeload.github.com/cfware/add-event-listener/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cfware%2Fadd-event-listener/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259752031,"owners_count":22905969,"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-24T10:18:34.979Z","updated_at":"2025-06-14T03:05:23.340Z","avatar_url":"https://github.com/cfware.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @cfware/add-event-listener [![NPM Version][npm-image]][npm-url]\n\nCalls owner.addEventListener and returns a function to remove the listener.\n\n## Usage\n\n```js\nimport addEventListener from '@cfware/add-event-listener';\n\nclass MyElement extends HTMLElement {\n\tconnectedCallback() {\n\t\tthis._cleanupFn = addEventListener(window, 'click', () =\u003e console.log('click'));\n\t}\n\n\tdisconnectedCallback() {\n\t\tthis._cleanupFn();\n\t}\n}\n```\n\n\n[npm-image]: https://img.shields.io/npm/v/@cfware/add-event-listener.svg\n[npm-url]: https://npmjs.org/package/@cfware/add-event-listener\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcfware%2Fadd-event-listener","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcfware%2Fadd-event-listener","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcfware%2Fadd-event-listener/lists"}