{"_id":"@tootallnate/once","_rev":"9-fc7839e3cdffb2a6f9b5189ce9faf8d3","name":"@tootallnate/once","dist-tags":{"latest":"3.0.1"},"versions":{"1.0.0":{"name":"@tootallnate/once","version":"1.0.0","keywords":[],"author":{"url":"http://n8.io/","name":"Nathan Rajlich","email":"nathan@tootallnate.net"},"license":"MIT","_id":"@tootallnate/once@1.0.0","maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"}],"homepage":"https://github.com/TooTallNate/once#readme","bugs":{"url":"https://github.com/TooTallNate/once/issues"},"dist":{"shasum":"9c13c2574c92d4503b005feca8f2e16cc1611506","tarball":"https://registry.npmjs.org/@tootallnate/once/-/once-1.0.0.tgz","fileCount":4,"integrity":"sha512-KYyTT/T6ALPkIRd2Ge080X/BsXvy9O0hcWTtMWkPvwAwF99+vn6Dv4GzrFT/Nn1LePr+FFDbRXXlqmsy9lw2zA==","signatures":[{"sig":"MEYCIQDkVuMlxE812OE/iMKZal/OcKOtbX8Bi0F+V1s1uRWObgIhAIe/UAY9fkQXncHFWazwa3/q4ByGoOzFYVXBNW4BcdRg","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":3117,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeP0i1CRA9TVsSAnZWagAAFSgP/R0PCo/C42TfQ3mzgFrX\nraRbBt38l3NF/3vehClfhnjmLvrMiV+PYderY153TTl/h1kQYJUp1CUp24BW\n7ZXyO78vsjt1wns02jIenUnLxjZhnCMrWgfe3DTBDVPg127R2PhNqNcZipZs\nTAe5H+DCiUTo/Tx3Ahwx6+HjURFYjb6inbH/SC6pe2VHHSCMhu+kS09w8Syx\nfrUcW2L5Li9xekQEPgEjjzOD2xjDRKyjjZaZP5D8z641DIDcDITJah4x8LLL\nyimRC49+joxUvgVzZJ0W/pNVwAzeJNxNOtMEg4cSvPVpfSqOQNG6OhaSrJaV\nTxH22jbRsdT6HWUztJmy9MJL3yZKpz7+YRwrYmlvUMjHCdH+FX8x2wvwNjW5\n/Nwu6msZnpa6GS5kPSr1voVYeOQ3IqenyS0tmVCcEISOYHFNm1rohmz5qisP\nnKCkSLK0yah/wSvmJyr4AkW4veaDtUG5bw6Sq2wFLivUrObUaPMECYDrD1xX\nuKYa2u8O5X4jrm5RS7hm3lKDum4hve2tshRQKS8CCigAqukqNwA72VIWb3Jc\nwdYNNRdTNtAfPtSGmM/MYYwWRLmS5EMNT42f/TessTv+Wy4wMsjvoILg739c\nHtmv80tHHMuqdeJ0zyRO+HQvHznzlf2k2tGybmyZ8udS6C1+yougzbVnATUD\nyaxG\r\n=MOm6\r\n-----END PGP SIGNATURE-----\r\n"},"main":"./dist/index.js","types":"./dist/index.d.ts","engines":{"node":">= 6"},"gitHead":"e3d8461b1bfa00b41329816f0caec8b9c7529158","scripts":{"test":"mocha --reporter spec","build":"tsc","prebuild":"rimraf dist","test-lint":"eslint src --ext .js,.ts","prepublishOnly":"npm run build"},"_npmUser":{"name":"tootallnate","email":"nathan@tootallnate.net"},"repository":{"url":"git://github.com/TooTallNate/once.git","type":"git"},"_npmVersion":"6.13.7","description":"Creates a Promise that waits for a single event","directories":{},"_nodeVersion":"12.15.0","_hasShrinkwrap":false,"devDependencies":{"mocha":"^6.2.2","eslint":"5.16.0","rimraf":"^3.0.0","typescript":"^3.7.3","@types/node":"^12.12.11","eslint-plugin-react":"7.12.4","eslint-config-airbnb":"17.1.0","eslint-plugin-import":"2.16.0","eslint-config-prettier":"4.1.0","eslint-plugin-jsx-a11y":"6.2.1","@typescript-eslint/parser":"1.1.0","@typescript-eslint/eslint-plugin":"1.6.0","eslint-import-resolver-typescript":"1.1.1"},"_npmOperationalInternal":{"tmp":"tmp/once_1.0.0_1581205684926_0.4139655088212628","host":"s3://npm-registry-packages"}},"1.1.0":{"name":"@tootallnate/once","version":"1.1.0","keywords":[],"author":{"url":"http://n8.io/","name":"Nathan Rajlich","email":"nathan@tootallnate.net"},"license":"MIT","_id":"@tootallnate/once@1.1.0","maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"}],"homepage":"https://github.com/TooTallNate/once#readme","bugs":{"url":"https://github.com/TooTallNate/once/issues"},"dist":{"shasum":"6c8342b7d64b1ce1f9a8392c1f21b0da41e1f582","tarball":"https://registry.npmjs.org/@tootallnate/once/-/once-1.1.0.tgz","fileCount":4,"integrity":"sha512-5v6eE6InDzX7g1T7tP5enDuPou2R9fuSRk+aD8ZJ822TfECtgBjnBrCFW4qC2yGNK+UUhPUhycC05Df5RgsnTw==","signatures":[{"sig":"MEYCIQCahoAXWp3PmaWfm5z9I5gdesGrDD25u+u/3498NyxKdwIhAIvTW8fnU31iNVqoOg6wo8DAU+eKc0ZT/FxiaSc2UKe+","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":3917,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeniHvCRA9TVsSAnZWagAA4p0P/j1hIFLYjiWVm6GxfEzv\nleS5Wi1viKQJVUEcPZ8RqWe78oL/sHBL93LsvSYACaft0wdvuATbcKLRVBYj\n2oqbReKyO0R9+D3BOG26hTTQjpsdJUfz/KaYwOqjIzR9noGQ1guf7Fpu8aHh\nfDh5eRdGZU0/uCPWROhLlAi9CE8g6Y2PTPKAdoV2WCCAARBhgZbZPqTt8XJt\njqOscByHJx8pon+pC/6BkDZKTJ7TAM8Pa37f2rUbPtBvmYD1NOGfvyUSzWV+\nRETJesblrpGV2D6lVLF9UXHnOa2IHX4cOA/CYucfLyP4pr2/wHBERDguSrx4\nZPZR3pP4DYe4liznaUoVL3bCLxBXkEr8HtDMf1RmXi3AbLcEamtmua4aiMon\nNNR7UultU6QmEEvYBb5FqeSg8hQKcbELvCynzp5lWjDWhOHDBFP4ViGM8I7F\nwOIE99Y7j6vlWx5Sopn/5N6vz83F4mnwy80x/M3BAA7lG7XdjrulFAy3zPRQ\nUrsp9peYkQ45e97idQzI0ykOQlXeN9b30ojbo5bATT65Hn2/OG4rADoeCgKH\nSo4LHWEu0o5uhqKWaLiioV+ZMX4doVX94QPW1qp44ZDNdskTTg7xCAe20txq\nMOGLnqbVdpuZq4MUJdEF2qYX/DXXlZ4f1/w6souJJ2WaILEXtXqhdNpELZQS\n/e7p\r\n=6uOB\r\n-----END PGP SIGNATURE-----\r\n"},"main":"./dist/index.js","types":"./dist/index.d.ts","engines":{"node":">= 6"},"gitHead":"ef4cb2ccd398f76498546588ca255220e74ac226","scripts":{"test":"mocha --reporter spec","build":"tsc","prebuild":"rimraf dist","test-lint":"eslint src --ext .js,.ts","prepublishOnly":"npm run build"},"_npmUser":{"name":"tootallnate","email":"nathan@tootallnate.net"},"repository":{"url":"git://github.com/TooTallNate/once.git","type":"git"},"_npmVersion":"6.13.4","description":"Creates a Promise that waits for a single event","directories":{},"_nodeVersion":"12.16.1","_hasShrinkwrap":false,"devDependencies":{"mocha":"^6.2.2","eslint":"5.16.0","rimraf":"^3.0.0","typescript":"^3.7.3","@types/node":"^12.12.11","eslint-plugin-react":"7.12.4","eslint-config-airbnb":"17.1.0","eslint-plugin-import":"2.16.0","eslint-config-prettier":"4.1.0","eslint-plugin-jsx-a11y":"6.2.1","@typescript-eslint/parser":"1.1.0","@typescript-eslint/eslint-plugin":"1.6.0","eslint-import-resolver-typescript":"1.1.1"},"_npmOperationalInternal":{"tmp":"tmp/once_1.1.0_1587421679230_0.7953557404424423","host":"s3://npm-registry-packages"}},"1.1.1":{"name":"@tootallnate/once","version":"1.1.1","keywords":[],"author":{"url":"http://n8.io/","name":"Nathan Rajlich","email":"nathan@tootallnate.net"},"license":"MIT","_id":"@tootallnate/once@1.1.1","maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"}],"homepage":"https://github.com/TooTallNate/once#readme","bugs":{"url":"https://github.com/TooTallNate/once/issues"},"dist":{"shasum":"e94fe74465c49c36094f403b56df7ae99861f466","tarball":"https://registry.npmjs.org/@tootallnate/once/-/once-1.1.1.tgz","fileCount":4,"integrity":"sha512-8foiU77JL9wR2yPZwecqN2YdJp/olC4CBVEaHdWWlz5rMQZcVEA3aXxlbfbUACVVxVwtTle3eYSnpBeKvIYcIg==","signatures":[{"sig":"MEUCIQC3JQrEE0GP04p8SUgsuEK47i6x40iKJcqmFS5IXZsDWgIgf9ZqiwIVYwpkFCauUaJR2KCuEb4oftB69KADGsP+qgI=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":3769,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJenjC0CRA9TVsSAnZWagAAtOcQAIxg+NzYDHDYZL4UOt8x\nvTcAu468CYxP9AmpqETGt0YyZweCdqKKVDV5hCV8kKUrmESikDf0oaz41aLL\nfskB6IXqzAOuk2RyEtoHUcJBtmXYoAfPfZj8MolDQOMA7ssjzp/vD6YZfOmr\neT3ZGXiffo3EXfnCcfr9RmHCc4uY2lCdYkp9iMeoIXMwxKwLw3IMtQmB5vpZ\nw5dBvrC/G7GWyZ0tE5KDHNRzhbRLq+iq4b5zvo4nzCz06HUTB+jPQP1TxUaI\nIRY4WAlOmPWbS5ZB+fW9aVEB+DgVgJrGbzQDoky4vx0Z+pURLWQR3aP+TTRS\nqK4Q6+C5GyK9/7skL6mUymgWvFfkxx0Piwz9WdT4L345BZDDrh2o6Da99A0l\nvkJxTe1sXY8IXnfd4P6tfnCSx1ubPzY7UO0Nr9RW5oSmfs/Fqp4JWK0/VLIF\nHiWXMBOZA/IFu6XtLbnmQhOlxWF2dKplUQeq15Pxy46Kvc94to941m6x4XwO\n+Dk4dAXQIKrTcYnNL/53u1A/0ZKM8YrC0Ij0Zvtcanp31BOjYBohTLvmRuOe\n+fizOzlMILGz/VyNNDHZ97nQk6OSUEzSfUycXMQmupAoCnQ4OAxqJSxRHH73\n4Wt8Au/9WrvasZEakbb1qQVeQvRELzxMj8iArzDE412YVCr4lCeTVSzm9ghO\n88fb\r\n=odp2\r\n-----END PGP SIGNATURE-----\r\n"},"main":"./dist/index.js","types":"./dist/index.d.ts","engines":{"node":">= 6"},"gitHead":"7cf120c15c61306b143eee6ba388e18c2af1f434","scripts":{"test":"mocha --reporter spec","build":"tsc","prebuild":"rimraf dist","test-lint":"eslint src --ext .js,.ts","prepublishOnly":"npm run build"},"_npmUser":{"name":"tootallnate","email":"nathan@tootallnate.net"},"repository":{"url":"git://github.com/TooTallNate/once.git","type":"git"},"_npmVersion":"6.13.4","description":"Creates a Promise that waits for a single event","directories":{},"_nodeVersion":"12.16.1","_hasShrinkwrap":false,"devDependencies":{"mocha":"^6.2.2","eslint":"5.16.0","rimraf":"^3.0.0","typescript":"^3.7.3","@types/node":"^12.12.11","eslint-plugin-react":"7.12.4","eslint-config-airbnb":"17.1.0","eslint-plugin-import":"2.16.0","eslint-config-prettier":"4.1.0","eslint-plugin-jsx-a11y":"6.2.1","@typescript-eslint/parser":"1.1.0","@typescript-eslint/eslint-plugin":"1.6.0","eslint-import-resolver-typescript":"1.1.1"},"_npmOperationalInternal":{"tmp":"tmp/once_1.1.1_1587425459623_0.22249323277893485","host":"s3://npm-registry-packages"}},"1.1.2":{"name":"@tootallnate/once","version":"1.1.2","keywords":[],"author":{"url":"http://n8.io/","name":"Nathan Rajlich","email":"nathan@tootallnate.net"},"license":"MIT","_id":"@tootallnate/once@1.1.2","maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"}],"homepage":"https://github.com/TooTallNate/once#readme","bugs":{"url":"https://github.com/TooTallNate/once/issues"},"dist":{"shasum":"ccb91445360179a04e7fe6aff78c00ffc1eeaf82","tarball":"https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz","fileCount":4,"integrity":"sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==","signatures":[{"sig":"MEUCIQCwIpkWwJ/FPu+EJSXpelQQLMQabXuL8L8g6f9BlsNQdwIgLcxy3jcKNxo8kHpx8YzTAGEEXuNBALGYiZquJvEPD00=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":4085,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJenxQMCRA9TVsSAnZWagAAvc8P/jKPoLqaDg/FCfMlvtbt\n0P+E0oIH42B8dljRqdFXJcYLodMtiJwzMnjN3FcztREci/o4boAe+mZs46FB\n6bsSMAiovIeGTZgsc6GOwYAcUeXYzhCWi2kTXBuPq48mYM5SE6QyCYtCcuco\nr0w+xcnScih+Gk1ER8IagU7mAeonltdQUQlxVYfJzrLpH0XgQTIlnEz51nzu\nLFPCyR6EInhKl3t45QfwN+/Z5Afxa+aEJRMETCOpxUmdNvG4dMlh8c3k0dGl\ncQKc/VQCAKHZI1hqXXadcq54eVAecNLkG5p2o3Dk+1vklpf43qoFC6tLgzXi\nbGA22rVR/nHZMtVTfHf1DbHzjqxBKVf4g7+1XmHVif1aOJmD6OjIoriNvAZP\nwVtRDEkiQ/fX35Cm5TDPKQg2i9qusgpAGKnqBV0JRzgR9NFeE+USJxp8nvdK\nP7Xh0+3iM61NkiwHb/QWN1lja4XO+3Z5uK21yn+2Y4ztIuHcankYrNUMXRSM\n0IELSovJWh+Ip0VNHnUFwHadEp1AKB/C4AFo+SxeSXMNmqlHrfE80uBLyyda\n4gjnpUnUm3eJbUAcS9+OvPeg5K4yTzsq0CfUgcvb6w88HEX8YTn0lGV/Leex\nzCNVpohntwpul+vS76FkZZcQIq9rNTFq+flJgMuQ7AF8hoyKzB8Amib3yTVg\n2JKi\r\n=w1wG\r\n-----END PGP SIGNATURE-----\r\n"},"main":"./dist/index.js","types":"./dist/index.d.ts","engines":{"node":">= 6"},"gitHead":"3948afcb5803013e184861943e0018e37830fcfe","scripts":{"test":"mocha --reporter spec","build":"tsc","prebuild":"rimraf dist","test-lint":"eslint src --ext .js,.ts","prepublishOnly":"npm run build"},"_npmUser":{"name":"tootallnate","email":"nathan@tootallnate.net"},"repository":{"url":"git://github.com/TooTallNate/once.git","type":"git"},"_npmVersion":"6.14.4","description":"Creates a Promise that waits for a single event","directories":{},"_nodeVersion":"10.20.1","_hasShrinkwrap":false,"devDependencies":{"mocha":"^6.2.2","eslint":"5.16.0","rimraf":"^3.0.0","typescript":"^3.7.3","@types/node":"^12.12.11","eslint-plugin-react":"7.12.4","eslint-config-airbnb":"17.1.0","eslint-plugin-import":"2.16.0","eslint-config-prettier":"4.1.0","eslint-plugin-jsx-a11y":"6.2.1","@typescript-eslint/parser":"1.1.0","@typescript-eslint/eslint-plugin":"1.6.0","eslint-import-resolver-typescript":"1.1.1"},"_npmOperationalInternal":{"tmp":"tmp/once_1.1.2_1587483659547_0.20019688772998245","host":"s3://npm-registry-packages"}},"2.0.0":{"name":"@tootallnate/once","version":"2.0.0","keywords":[],"author":{"url":"http://n8.io/","name":"Nathan Rajlich","email":"nathan@tootallnate.net"},"license":"MIT","_id":"@tootallnate/once@2.0.0","maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"}],"homepage":"https://github.com/TooTallNate/once#readme","bugs":{"url":"https://github.com/TooTallNate/once/issues"},"dist":{"shasum":"f544a148d3ab35801c1f633a7441fd87c2e484bf","tarball":"https://registry.npmjs.org/@tootallnate/once/-/once-2.0.0.tgz","fileCount":12,"integrity":"sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A==","signatures":[{"sig":"MEUCIQDJRLOn9FB5OudqkoDc1levBT0KxlClrAuQXHhLLqhnjwIgNCG2XdUx6puYPbXYD/JUJcj8z71yUv7UrByWV7I120I=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":16332},"jest":{"preset":"ts-jest","globals":{"ts-jest":{"diagnostics":false,"isolatedModules":true}},"verbose":false,"testMatch":["<rootDir>/test/**/*.test.ts"],"testEnvironment":"node"},"main":"./dist/index.js","types":"./dist/index.d.ts","engines":{"node":">= 10"},"gitHead":"b71b6e880044ab2110d3f2c753cd3d218e5e262e","scripts":{"test":"jest","build":"tsc","prebuild":"rimraf dist","prepublishOnly":"npm run build"},"_npmUser":{"name":"tootallnate","email":"nathan@tootallnate.net"},"repository":{"url":"git://github.com/TooTallNate/once.git","type":"git"},"_npmVersion":"6.14.15","description":"Creates a Promise that waits for a single event","directories":{},"_nodeVersion":"12.22.6","_hasShrinkwrap":false,"devDependencies":{"jest":"^27.2.1","rimraf":"^3.0.0","ts-jest":"^27.0.5","typescript":"^4.4.3","@types/jest":"^27.0.2","@types/node":"^12.12.11","abort-controller":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/once_2.0.0_1632354651709_0.44949087906019014","host":"s3://npm-registry-packages"}},"3.0.0":{"name":"@tootallnate/once","version":"3.0.0","keywords":[],"author":{"url":"http://n8.io/","name":"Nathan Rajlich","email":"nathan@tootallnate.net"},"license":"MIT","_id":"@tootallnate/once@3.0.0","maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"}],"homepage":"https://github.com/TooTallNate/once#readme","bugs":{"url":"https://github.com/TooTallNate/once/issues"},"dist":{"shasum":"d52238c9052d746c9689523e650160e70786bc9a","tarball":"https://registry.npmjs.org/@tootallnate/once/-/once-3.0.0.tgz","fileCount":15,"integrity":"sha512-OAdBVB7rlwvLD+DiecSAyVKzKVmSfXbouCyM5I6wHGi4MGXIyFqErg1IvyJ7PI1e+GYZuZh7cCHV/c4LA8SKMw==","signatures":[{"sig":"MEQCIAKqgfeKpxNBpZ2qzfI+LmrCMk/kj9hxnKBoT9lIDcbfAiBzi8T/WuQoZ/qPbm1Q2J9AyS6XEbRDzVYCMk8zPbCw6Q==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":25011,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh2ekhCRA9TVsSAnZWagAAk+sP/jPqUJNTMe4Q0cgzmuUH\n33zRhJSAWr/jKLz//AnY4kaZnKtMpob18BRdST+9efxKxpDSC05K3ZHboukm\nZlK+x2mMcSScVEPMppSMweJYpxGLlUW7puT7URGfNTrHvL6R1b6p5UT9iVRA\nYsDFduuuCCc7WBxQcGilTPIOlnxiZy4w1I9FMdmpk6nHeINIraWotcXsalgL\nJq3QsqL+O9f/PsApWhBP+viBUbGzsdsvW6+37U6+JHI/obJoTjdRc488ic2M\nckT3ESFpD2BSztEYiC+A6I8xE4trbbXB2I0dY2mRYH+5JqTXHPRnit+cCihH\ntC4ntATQgMK6MX7aCz0ZX+pzH+ZZrMhPGmCpzc4L93t6mxm89JV/6M9Ba7KE\nfRN/Qnr90cBfH3I1a/okhVKBPeimLckeAjFy16YsuavKsRFu/zgDeh2DbYxw\nKpy3MrZZSY0RlY/Z8FeEY+N/SqaO8D7Xql6Z1noCS35e4GepoM9d3xEa9axL\nXR/VtQqBQQYWg0opqCOpj0ivuKlq/10BFXfByzJeXTJgTHkr7Xs2uhbxodMs\n3QGeWF1Xx6AZVXO8KDnX3Vz64THev0RFR48lNGq3zBGm7MvEVtm4ArNgmVLl\nXJMGTq2JoSFXh/cSZrcZ1tDZ2CLcQqEgcwVC5HpBnmtkf6uvDcs9PHtobYvk\nrCzz\r\n=1uQi\r\n-----END PGP SIGNATURE-----\r\n"},"jest":{"preset":"ts-jest","globals":{"ts-jest":{"diagnostics":false,"isolatedModules":true}},"verbose":false,"testMatch":["<rootDir>/test/**/*.test.ts"],"testEnvironment":"node"},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","engines":{"node":">= 10"},"gitHead":"2bc2e134b7728a6b37c6838a3b5d5c290e60a539","scripts":{"test":"jest","build":"tsc","prebuild":"rimraf dist","prepublishOnly":"npm run build"},"_npmUser":{"name":"tootallnate","email":"nathan@tootallnate.net"},"repository":{"url":"git://github.com/TooTallNate/once.git","type":"git"},"_npmVersion":"6.14.15","description":"Creates a Promise that waits for a single event","directories":{},"_nodeVersion":"12.22.6","_hasShrinkwrap":false,"devDependencies":{"jest":"^27.2.1","rimraf":"^3.0.0","ts-jest":"^27.0.5","typescript":"^4.4.3","@types/jest":"^27.0.2","@types/node":"^12.12.11","abort-controller":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/once_3.0.0_1632734034811_0.33679291306743675","host":"s3://npm-registry-packages"}},"3.0.1":{"name":"@tootallnate/once","version":"3.0.1","description":"Creates a Promise that waits for a single event","type":"module","main":"./dist/index.js","types":"./dist/index.d.ts","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git://github.com/TooTallNate/once.git"},"keywords":[],"author":{"name":"Nathan Rajlich","email":"nathan@tootallnate.net","url":"http://n8.io/"},"license":"MIT","bugs":{"url":"https://github.com/TooTallNate/once/issues"},"devDependencies":{"@changesets/cli":"^2.29.8","@types/jest":"^27.0.2","@types/node":"^12.12.11","abort-controller":"^3.0.0","jest":"^27.2.1","rimraf":"^3.0.0","ts-jest":"^27.0.5","typescript":"^4.4.3"},"engines":{"node":">= 10"},"jest":{"preset":"ts-jest","globals":{"ts-jest":{"diagnostics":false,"isolatedModules":true}},"verbose":false,"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.test.ts"]},"scripts":{"prebuild":"rimraf dist","build":"tsc","test":"jest","changeset":"changeset","version":"changeset version","release":"pnpm build && changeset publish"},"_id":"@tootallnate/once@3.0.1","homepage":"https://github.com/TooTallNate/once#readme","_integrity":"sha512-VyMVKRrpHTT8PnotUeV8L/mDaMwD5DaAKCFLP73zAqAtvF0FCqky+Ki7BYbFCYQmqFyTe9316Ed5zS70QUR9eg==","_resolved":"/tmp/e0964137001fc860e5234484fa703b66/tootallnate-once-3.0.1.tgz","_from":"file:tootallnate-once-3.0.1.tgz","_nodeVersion":"24.13.0","_npmVersion":"11.9.0","dist":{"integrity":"sha512-VyMVKRrpHTT8PnotUeV8L/mDaMwD5DaAKCFLP73zAqAtvF0FCqky+Ki7BYbFCYQmqFyTe9316Ed5zS70QUR9eg==","shasum":"d580decb59cb41a15856387a86800838102daf44","tarball":"https://registry.npmjs.org/@tootallnate/once/-/once-3.0.1.tgz","fileCount":15,"unpackedSize":25919,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@tootallnate%2fonce@3.0.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIBTRWCddKC0bjqo60jRq4XY1wgN6dM9qAWtBYhl4Ufw7AiB90XtMTrag7hRTsq40OjPXx8p9nr8sVJxFuIMGGgY75g=="}]},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:093b5aa9-9715-4fab-809d-d3f5c61f54ef"}},"directories":{},"maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/once_3.0.1_1770661177633_0.5134475689822235"},"_hasShrinkwrap":false}},"time":{"created":"2020-02-08T23:48:04.879Z","modified":"2026-02-09T18:19:38.417Z","1.0.0":"2020-02-08T23:48:05.016Z","1.1.0":"2020-04-20T22:27:59.335Z","1.1.1":"2020-04-20T23:30:59.787Z","1.1.2":"2020-04-21T15:40:59.696Z","2.0.0":"2021-09-22T23:50:52.041Z","3.0.0":"2021-09-27T09:13:54.973Z","3.0.1":"2026-02-09T18:19:37.836Z"},"bugs":{"url":"https://github.com/TooTallNate/once/issues"},"author":{"name":"Nathan Rajlich","email":"nathan@tootallnate.net","url":"http://n8.io/"},"license":"MIT","homepage":"https://github.com/TooTallNate/once#readme","keywords":[],"repository":{"type":"git","url":"git://github.com/TooTallNate/once.git"},"description":"Creates a Promise that waits for a single event","maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"}],"readme":"# @tootallnate/once\n\n### Creates a Promise that waits for a single event\n\n## Installation\n\nInstall with `npm`:\n\n```bash\n$ npm install @tootallnate/once\n```\n\n## API\n\n### once(emitter: EventEmitter, name: string, opts?: OnceOptions): Promise&lt;[...Args]&gt;\n\nCreates a Promise that waits for event `name` to occur on `emitter`, and resolves\nthe promise with an array of the values provided to the event handler. If an\n`error` event occurs before the event specified by `name`, then the Promise is\nrejected with the error argument.\n\n```typescript\nimport once from '@tootallnate/once';\nimport { EventEmitter } from 'events';\n\nconst emitter = new EventEmitter();\n\nsetTimeout(() => {\n    emitter.emit('foo', 'bar');\n}, 100);\n\nconst [result] = await once(emitter, 'foo');\nconsole.log({ result });\n// { result: 'bar' }\n```\n\n#### Promise Strong Typing\n\nThe main feature that this module provides over other \"once\" implementations is that\nthe Promise that is returned is _**strongly typed**_ based on the type of `emitter`\nand the `name` of the event. Some examples are shown below.\n\n_The process \"exit\" event contains a single number for exit code:_\n\n```typescript\nconst [code] = await once(process, 'exit');\n//     ^ number\n```\n_A child process \"exit\" event contains either an exit code or a signal:_\n\n```typescript\nconst child = spawn('echo', []);\nconst [code, signal] = await once(child, 'exit');\n//     ^ number | null\n//           ^ string | null\n```\n\n_A forked child process \"message\" event is type `any`, so you can cast the Promise directly:_\n\n```typescript\nconst child = fork('file.js');\n\n// With `await`\nconst [message, _]: [WorkerPayload, unknown] = await once(child, 'message');\n\n// With Promise\nconst messagePromise: Promise<[WorkerPayload, unknown]> = once(child, 'message');\n\n// Better yet would be to leave it as `any`, and validate the payload\n// at runtime with i.e. `ajv` + `json-schema-to-typescript`\n```\n\n_If the TypeScript definition does not contain an overload for the specified event name, then the Promise will have type `unknown[]` and your code will need to narrow the result manually:_\n\n```typescript\ninterface CustomEmitter extends EventEmitter {\n    on(name: 'foo', listener: (a: string, b: number) => void): this;\n}\n\nconst emitter: CustomEmitter = new EventEmitter();\n\n// \"foo\" event is a defined overload, so it's properly typed\nconst fooPromise = once(emitter, 'foo');\n//    ^ Promise<[a: string, b: number]>\n\n// \"bar\" event in not a defined overload, so it gets `unknown[]`\nconst barPromise = once(emitter, 'bar');\n//    ^ Promise<unknown[]>\n```\n\n### OnceOptions\n\n-   `signal` - `AbortSignal` instance to unbind event handlers before the Promise has been fulfilled.\n","readmeFilename":"README.md"}