{"id":18609718,"url":"https://github.com/unlight/onn","last_synced_at":"2025-11-02T20:30:28.624Z","repository":{"id":57314799,"uuid":"193366550","full_name":"unlight/onn","owner":"unlight","description":"Event emitter using DOM's addEventListener/dispatchEvent","archived":false,"fork":false,"pushed_at":"2019-06-23T17:52:20.000Z","size":11,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-27T05:17:04.945Z","etag":null,"topics":["bus","emit-events","emitter","event-emitter","eventbus","events","pubsub"],"latest_commit_sha":null,"homepage":"","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/unlight.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}},"created_at":"2019-06-23T15:45:54.000Z","updated_at":"2019-07-05T13:41:59.000Z","dependencies_parsed_at":"2022-09-12T15:02:13.270Z","dependency_job_id":null,"html_url":"https://github.com/unlight/onn","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Fonn","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Fonn/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Fonn/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Fonn/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/unlight","download_url":"https://codeload.github.com/unlight/onn/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239400596,"owners_count":19632049,"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":["bus","emit-events","emitter","event-emitter","eventbus","events","pubsub"],"created_at":"2024-11-07T03:07:03.701Z","updated_at":"2025-11-02T20:30:28.585Z","avatar_url":"https://github.com/unlight.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# onn\nEvent emitter using DOM's addEventListener/dispatchEvent\n\n## Usage\n```js\nconst { on } = require('onn');\n\nconst off = on(document, 'login', (event) =\u003e {\n    console.log(`Hello, ${event.detail.name}!`); // =\u003e Hello, Bob!\n});\ndocument.dispatchEvent(new CustomEvent('login', { detail: { name: 'Bob' } }));\noff(); // Unsubscribe\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funlight%2Fonn","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Funlight%2Fonn","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funlight%2Fonn/lists"}