New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

resolve-when

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

resolve-when - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

8

index.js

@@ -0,1 +1,9 @@

/**
* Returns a promise that resolves once condition is met
*
* @param {function} condition - Return `true` to cause resolveWhen to resolve
* @param {Object} options
* @param {Number} options.max - The maximum number of times that `condition` should run
* @param {Number} options.interval - Time, in milliseconds, to wait between running `condition`
*/
function resolveWhen(condition = () => true, { max, interval = 50 } = {}) {

@@ -2,0 +10,0 @@ return new Promise((resolve, reject) => {

2

package.json
{
"name": "resolve-when",
"version": "1.0.3",
"version": "1.0.4",
"description": "Returns a promise that resolves once condition is met",

@@ -5,0 +5,0 @@ "author": {

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