Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

await-event

Package Overview
Dependencies
Maintainers
3
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

await-event - npm Package Compare versions

Comparing version 1.0.0 to 2.0.0

History.md

12

index.js

@@ -0,8 +1,8 @@

'use strict'
module.exports = function await(event) {
var self = this
return function (done) {
if (event !== 'error') done = done.bind(null, null)
self.once(event, done)
}
module.exports = function(event) {
return new Promise((resolve, reject) => {
const done = event === 'error' ? reject : resolve
this.once(event, done)
})
}
{
"name": "await-event",
"description": "yield an event with generators",
"version": "1.0.0",
"version": "2.0.0",
"author": {

@@ -18,3 +18,17 @@ "name": "Jonathan Ong",

"await"
],
"scripts": {
"test": "jest --forceExit",
"test-cov": "jest --coverage --forceExit"
},
"devDependencies": {
"co": "^4.6.0",
"jest": "^18.1.0"
},
"jest": {
"testEnvironment": "node"
},
"files": [
"index.js"
]
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc