{"name":"nanoevents","version":"8.0.0","description":"Simple and tiny (130 bytes) event emitter library","keywords":["EventEmitter","Events","emit","emitter","event","pub/sub","publish","reactor","subscribe"],"author":{"name":"Andrey Sitnik","email":"andrey@sitnik.ru"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/ai/nanoevents.git"},"engines":{"node":"^16.0.0 || ^18.0.0 || >=20.0.0"},"sideEffects":false,"type":"module","types":"./index.d.ts","exports":{".":"./index.js","./package.json":"./package.json"},"gitHead":"f27ac4eb1dfb5dc518b9107aab1d79d0fa881aa3","bugs":{"url":"https://github.com/ai/nanoevents/issues"},"homepage":"https://github.com/ai/nanoevents#readme","_id":"nanoevents@8.0.0","_nodeVersion":"20.3.1","_npmVersion":"9.6.7","dist":{"integrity":"sha512-bYYwNCdNc5ea6/Lwh1uioU1/7aaKa3EPmNQ2weTm8PWSpbWrsaWHePe0Zq4SF+D3F3JX3cn+QdktOPCf1meOqw==","shasum":"d58d5cf69b172d794707b2468bdaccc415ad23b6","tarball":"http://registry-npm.ywwl.com/nanoevents/download/nanoevents-8.0.0.tgz","fileCount":5,"unpackedSize":4768,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDNqrEKhWsYuvjrRwU/Nc4ouPIsRRCObeQJpSeivriyrgIhAK6cU0RZAbGRxIzgPkI9n+BiApEIZDYJBfiKBT2Pmq6Y"}],"size":2370,"noattachment":false,"key":"/nanoevents/-/nanoevents-8.0.0.tgz"},"_npmUser":{"name":"ai","email":"andrey@sitnik.ru"},"directories":{},"maintainers":[{"name":"ai","email":"andrey@sitnik.ru"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/nanoevents_8.0.0_1688212261650_0.9953607811736611"},"_hasShrinkwrap":false,"readme":"# Nano Events\n\nSimple and tiny event emitter library for JavaScript.\n\n* Only **107 bytes** (minified and brotlied).\n  It uses [Size Limit] to control size.\n* The `on` method returns `unbind` function. You don’t need to save\n  callback to variable for `removeListener`.\n* TypeScript and ES modules support.\n* No aliases, just `emit` and `on` methods.\n  No Node.js [EventEmitter] compatibility.\n\n```js\nimport { createNanoEvents } from 'nanoevents'\n\nconst emitter = createNanoEvents()\n\nconst unbind = emitter.on('tick', volume => {\n  summary += volume\n})\n\nemitter.emit('tick', 2)\nsummary //=> 2\n\nunbind()\nemitter.emit('tick', 2)\nsummary //=> 2\n```\n\n[EventEmitter]: https://nodejs.org/api/events.html\n[Size Limit]:   https://github.com/ai/size-limit\n\n<a href=\"https://evilmartians.com/?utm_source=nanoevents\">\n  <img src=\"https://evilmartians.com/badges/sponsored-by-evil-martians.svg\"\n       alt=\"Sponsored by Evil Martians\" width=\"236\" height=\"54\">\n</a>\n\n\n## Docs\nRead full docs **[here](https://github.com/ai/nanoevents#readme)**.\n","publish_time":1688212261858,"_cnpm_publish_time":1688212261858,"dist-tags":{"latest":"10.0.0"}}