{"_id":"page-bus","_rev":"20-ff9e55215adcdcf9380797e91de2eb0f","name":"page-bus","description":"share an event emitter among pages and frames on the same domain","dist-tags":{"latest":"3.0.1"},"versions":{"1.0.0":{"name":"page-bus","version":"1.0.0","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"isarray":"~0.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","event","emitter","bus","SharedWorker","worker","webworker","createObjectURL","iframe","postMessage"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"e58cdd2b7b6b957be340272c344f5feec3be59d9","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@1.0.0","_shasum":"087257c759823bfc3ef4fd24bdd84501ae80761c","_from":".","_npmVersion":"2.1.3","_nodeVersion":"0.10.31","_npmUser":{"name":"substack","email":"mail@substack.net"},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"dist":{"shasum":"087257c759823bfc3ef4fd24bdd84501ae80761c","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-1.0.0.tgz","integrity":"sha512-l27MNmSaYdnnCq77U1SXL75Yp10WEyrvKm3s49/FBKiQZYFjiZHq7zsTDknS6xkcYvC2MEUqfYlZLkoYzMWjww==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGRHOTsUdwHMLy1I5auwIv05VGC1GXt+0cp7CLf3kPwHAiEA08FWwEt7e5yhpcW5J2/E23brPubilTLlEXEagPyrZK0="}]},"directories":{}},"1.0.1":{"name":"page-bus","version":"1.0.1","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"isarray":"~0.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","event","emitter","bus","SharedWorker","worker","webworker","createObjectURL","iframe","postMessage","offline","offline-first"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"52ea37c808b3c9451b6aa1d3731051c8cc560773","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@1.0.1","_shasum":"96a907da4a09a7a42f0b67475609379227253fef","_from":".","_npmVersion":"2.1.3","_nodeVersion":"0.10.31","_npmUser":{"name":"substack","email":"mail@substack.net"},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"dist":{"shasum":"96a907da4a09a7a42f0b67475609379227253fef","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-1.0.1.tgz","integrity":"sha512-n04F3sZKa47PCHWO/EwzC8kGw7Z5Q5xxznGcB5MxYJ4kFFzpgs9w4BTv5RL1FCbXiKaCzk2PlhnRyjTj/KQVGA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDs6FqIP6W+9Bwf5dK/168hQyTNAvf2qu+sVLGv3d2O6AIhAOBaFuP3Ny2c3ccTo3mwKoZc9T9CWBg07R26mOcbyQEG"}]},"directories":{}},"1.0.2":{"name":"page-bus","version":"1.0.2","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"isarray":"~0.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","event","emitter","bus","SharedWorker","worker","webworker","createObjectURL","iframe","postMessage","offline","offline-first"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"f72cf041b1e178cb6a52baa54b27fdf2a452ee43","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@1.0.2","_shasum":"72998762bb1f640b321602068d56a9e05aad44e4","_from":".","_npmVersion":"2.1.3","_nodeVersion":"0.10.31","_npmUser":{"name":"substack","email":"mail@substack.net"},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"dist":{"shasum":"72998762bb1f640b321602068d56a9e05aad44e4","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-1.0.2.tgz","integrity":"sha512-DYhqRy/DGvh0YB7TJTaH7AoNzs9LxRLwLdsILBGsoXg/49ASz3/8JXoalTAUltI0JHOLJDvrIgm16/qSr7G42A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCBypK0an9cuppTEAlDkyi9hIK7o4UhsE5k0Vm7DY1OzQIgMWr+JZSSc8hGgHlWKaQ4Ljnqh51Cf8uLuSRzFZWrR4Y="}]},"directories":{}},"1.0.3":{"name":"page-bus","version":"1.0.3","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"isarray":"~0.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","event","emitter","bus","SharedWorker","worker","webworker","createObjectURL","iframe","postMessage","offline","offline-first"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"40bb2ced7da238f9664f726484134b1fdfd5c222","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@1.0.3","_shasum":"562c466028c4ecf57029c51412e0dbaa85a39e69","_from":".","_npmVersion":"2.1.3","_nodeVersion":"0.10.31","_npmUser":{"name":"substack","email":"mail@substack.net"},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"dist":{"shasum":"562c466028c4ecf57029c51412e0dbaa85a39e69","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-1.0.3.tgz","integrity":"sha512-Pr1ex3QDyREb2D9xTxTreLFqwAyPUxyYfgUrNeaAAbmkMJshFB5KeWRq36GGRx5h+W47pduNnW5Tr76oM+QFvQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCrjQEkam5HiJj8wWZRixh1BrOyP7XR0iLH0VidlkwD9wIgYBPhBV6+Mv8O3gfxy2TyrdTAuOc19mrW3DQlIHDsx44="}]},"directories":{}},"2.0.0":{"name":"page-bus","version":"2.0.0","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"isarray":"~0.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","event","emitter","bus","SharedWorker","worker","webworker","createObjectURL","iframe","postMessage","offline","offline-first"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"060f1a3b092bcb007ddc7b4a0f3d18f012efe7b5","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@2.0.0","_shasum":"e9805961ce378eb06c701da22bebec0d7259e4be","_from":".","_npmVersion":"2.1.3","_nodeVersion":"0.10.31","_npmUser":{"name":"substack","email":"mail@substack.net"},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"dist":{"shasum":"e9805961ce378eb06c701da22bebec0d7259e4be","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-2.0.0.tgz","integrity":"sha512-JnNJ9oXwWDQX9FUOP0OSsISs++zrSN/PBDQiqXQ897gc52ee8H1Vco0E4ZoI+rV1lqQNBx198Co+gV8e0zBOtQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIA1IiHnTxCx8V9NYmYr/CNFsLOR6BtLOZ9cKv3aHFj1bAiAz1JaILFZdWdAbd5eB8MT5ilSWdcOM7JY5bEg7IcKayg=="}]},"directories":{}},"2.1.0":{"name":"page-bus","version":"2.1.0","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"isarray":"~0.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","event","emitter","bus","SharedWorker","worker","webworker","createObjectURL","iframe","postMessage","offline","offline-first"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"c9b5d45a15b3fc2235c5a4cc612b35037be00fb4","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@2.1.0","_shasum":"eb82724f7cac68828bd1a75c94896e7d9ff0d463","_from":".","_npmVersion":"2.1.3","_nodeVersion":"0.10.31","_npmUser":{"name":"substack","email":"mail@substack.net"},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"dist":{"shasum":"eb82724f7cac68828bd1a75c94896e7d9ff0d463","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-2.1.0.tgz","integrity":"sha512-N0K45DPAXEObC4QHdhmte/4/gR5cpU1AUDN2hQ9oE3jGoCD/zRDUHMsfSKJ4GGow+A4CaU+dx5B32RoNEGVemw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCgXxR3QLTjbNm8L+TTqtUQYxetqmZ87vEeBNCW7W/T/gIgRpcEUOW2LGPz8kafZ4GLP4wSi5eHf3GD3XuOoVZOSd0="}]},"directories":{}},"2.1.1":{"name":"page-bus","version":"2.1.1","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"isarray":"~0.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","event","emitter","bus","SharedWorker","worker","webworker","createObjectURL","iframe","postMessage","offline","offline-first"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"3fc1e98f044a34dbefcafc2d2e3994c9dd4cf6b9","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@2.1.1","_shasum":"6cd0b9b028438c21b6510683f6b9cf7fcf4a3104","_from":".","_npmVersion":"2.9.0","_nodeVersion":"2.0.0","_npmUser":{"name":"substack","email":"substack@gmail.com"},"dist":{"shasum":"6cd0b9b028438c21b6510683f6b9cf7fcf4a3104","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-2.1.1.tgz","integrity":"sha512-sL47A64XwZ3DEfQxaXBaB8xHKaFAol2MkNtlrH6LlWenrNgLfNiLNPNITqRStQN6UUCqbTh5x4YHrg9uLzHUEA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDc4aMKitcLdowYEbLPf7RpvjeWOM1MuIDIcRamck6pHAiBNC9IGqlANEVykVY33bsNt/COx9Yglz0gAuhxp5tjwrA=="}]},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"directories":{}},"3.0.0":{"name":"page-bus","version":"3.0.0","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"inherits":"^2.0.1","isarray":"~0.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","bus","emitter","event","localStorage","storage","iframe","offline","offline-first","postMessage","webworker","worker"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"69d73de94033c785fe939065c4326f0b09b2bc0d","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@3.0.0","_shasum":"541e53cb01b9547d4d83c99a1e181e28f932c4c5","_from":".","_npmVersion":"3.0.0","_nodeVersion":"2.0.0","_npmUser":{"name":"substack","email":"substack@gmail.com"},"dist":{"shasum":"541e53cb01b9547d4d83c99a1e181e28f932c4c5","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-3.0.0.tgz","integrity":"sha512-pnZFCEuttIlA3EOO3bWp+GDEY5J/X8vXS2F0v5UxTAv8M8wncOnPYcRCS0FYFdBMzykqAWnyvDrjRpNwUPiONw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDAEDgld6uTVIvXKwoojiSsF3W3PZBhdzKvpCHHMxXBJQIgaIZbS/zTdPf5RhDCd9x3+eXht3AWjxH7dcqa3bfSQIo="}]},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"directories":{}},"3.0.1":{"name":"page-bus","version":"3.0.1","description":"share an event emitter among pages and frames on the same domain","main":"index.js","dependencies":{"inherits":"^2.0.1"},"devDependencies":{"tape":"^3.0.0"},"scripts":{"test":"tape test/*.js"},"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","bus","emitter","event","localStorage","storage","iframe","offline","offline-first","postMessage","webworker","worker"],"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"license":"MIT","gitHead":"e71ae5dd821ac44a21d5b271cb59410c8d2efc73","bugs":{"url":"https://github.com/substack/page-bus/issues"},"_id":"page-bus@3.0.1","_shasum":"701d3906bcebab8524e2390bf271a220e4f12e09","_from":".","_npmVersion":"3.0.0","_nodeVersion":"2.0.0","_npmUser":{"name":"substack","email":"substack@gmail.com"},"dist":{"shasum":"701d3906bcebab8524e2390bf271a220e4f12e09","tarball":"https://registry.npmjs.org/page-bus/-/page-bus-3.0.1.tgz","integrity":"sha512-sv4SaVMKSADwO7wOUvWKZJNYCZCRpsA5JQKS+SZSqZigIwzVNlqu0vGjeNwTDBJmVtUIGp2lmE+ozQpM5aAYpA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDgwS6z+1+r/WcPd72ZTRz7HOlka8p299cRM8v8ycTTgwIhAMQVvF34eOJt4geSNlRed8QKpoMygbm5c6v7xoPXLZbO"}]},"maintainers":[{"name":"substack","email":"mail@substack.net"}],"directories":{}}},"readme":"# page-bus\n\nshare an event emitter among pages and frames on the same domain\n\nThis module works offline and does not rely on any network IO.\n\nBehind the scenes, the localStorage API and the window `'storage'` event is used to synchronize\ncross-page events.\n\nPreviously this module used a shared worker, but shared workers need to elect a\nmaster for the `URL.createObjectURL()` api which got very complicated.\n\n# example\n\nJust create a bus, which returns an event emitter:\n\n``` js\nvar createBus = require('page-bus');\nvar bus = createBus();\n\nbus.on('hello', function (msg) {\n    console.log('msg=', msg);\n});\n\nbus.emit('hello', Date.now());\n```\n\nCompile with browserify then open this page up on a few tabs.\n\nThe messages get shared hooray!\n\n[Check out the demo on neocities.](https://substack.neocities.org/pagebus.html)\n\n# methods\n\n``` js\nvar createBus = require('page-bus')\n```\n\n## var bus = createBus(opts)\n\nCreate a new event emitter `bus`.\n\n* `opts.key` - the string key to save data. default: `'page-bus'`. By using a\ndifferent value, you can create namespaces.\n\nAll other pages on the same domain in the same browser will be able to open the\nevent emitter.\n\n# install\n\nWith [npm](https://npmjs.org) do:\n\n```\nnpm install page-bus\n```\n\n# license\n\nMIT\n","maintainers":[{"email":"nopersonsmodules@gmail.com","name":"nopersonsmodules"}],"time":{"modified":"2022-11-08T10:40:08.729Z","created":"2014-11-13T05:24:40.575Z","1.0.0":"2014-11-13T05:24:40.575Z","1.0.1":"2014-11-13T05:57:54.718Z","1.0.2":"2014-11-13T08:12:07.358Z","1.0.3":"2014-11-13T21:58:09.127Z","2.0.0":"2014-11-13T22:07:03.180Z","2.1.0":"2014-11-14T12:34:34.330Z","2.1.1":"2015-05-13T10:52:59.098Z","3.0.0":"2015-07-07T11:35:35.355Z","3.0.1":"2015-07-07T11:42:00.285Z"},"homepage":"https://github.com/substack/page-bus","keywords":["browser","bus","emitter","event","localStorage","storage","iframe","offline","offline-first","postMessage","webworker","worker"],"repository":{"type":"git","url":"git://github.com/substack/page-bus.git"},"author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"},"bugs":{"url":"https://github.com/substack/page-bus/issues"},"license":"MIT","readmeFilename":"readme.markdown","users":{"j.su":true}}