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

kgo

Package Overview
Dependencies
Maintainers
2
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

kgo - npm Package Compare versions

Comparing version 3.1.0 to 3.1.1

2

package.json
{
"name": "kgo",
"version": "3.1.0",
"version": "3.1.1",
"description": "Flow control the super easy way",

@@ -5,0 +5,0 @@ "main": "kgo.js",

@@ -92,3 +92,3 @@ kgo

You will often not need the result of a dependency, and it's annoying to have unused parameters in your functions.
You can specify that you have a dependancy, whos result you don't want, by prefixing the dependancy name with an exclamation mark:
You can specify that you have a dependency, whos result you don't want, by prefixing the dependency name with an exclamation mark:

@@ -162,2 +162,15 @@ ``` javascript

## kgo.sync
Sometimes you want to just run a synchonous function as a step in kgo, to do this you can use `kgo.sync`, which will return a callback-passing-style version.
``` javascript
kgo
('task1', task1);
('task2', ['task1'], kgo.sync(function(x){ return x + 1 }))
('task3', ['task2'], task3);
```
## Errors

@@ -167,2 +180,3 @@

any task that has a dependency on any error task will resolve if any error dependency is resolved.

@@ -184,3 +198,3 @@ ``` javascript

there is an implicit taskName, `*error`, that will resolve any task that depends on it, even if it has other unresolved dependencies.
there is an implicit error task, `*`, that will resolve to the first of any error that occurs.

@@ -191,3 +205,3 @@ ``` javascript

(another task)
(['*error'], function(error){
(['*'], function(error){
// Called if any error occurs in any task

@@ -206,5 +220,5 @@ });

('result', ['task1', 'task2'], ...)
(['*error', 'result'], callback); // Will be called either if any task errors, OR if result resolves.
(['*', 'result'], callback); // Will be called either if any task errors, OR if result resolves.
}
```
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