Security News
Opengrep Emerges as Open Source Alternative Amid Semgrep Licensing Controversy
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
adonis-co-ware
Advanced tools
Ware inspired, easily create your own middleware layer using generators via co.
var ware = require('..');
var w = ware()
.use(function *(next) {
this.x = 'hello';
yield next;
})
.use(function *(next) {
this.y = 'world';
yield next;
})
.use(function *(next) {
yield next;
});
w.run({}, {}, function *() {
console.log(this.x, this.y);
});
Print the arguments of input.
var ware = require('..');
var w = ware()
.use(function *(next) {
console.log(this.input); // 1, 2, 3
yield next;
});
w.run(1, 2, 3);
Handles error.
var ware = require('..');
var w = ware()
.use(function *(next) {
if ('42' != this.input[0].life) throw new Error();
yield next;
})
.use(function *(next) {
console.log('yes!');
})
.on('error', function (err) {
console.log('no!');
});
w.run({ life: '41' }); // "no!"
w.run({ life: '42' }); // "yes!"
Create a new list of middleware.
Push a middleware fn(GeneratorFunction) onto the list. If the middleware has an arity of one more than the input to run it's an error middleware.
Runs the middleware functions with input... and optionally calls callback(GeneratorFunction).
Clear the middleware.
MIT
FAQs
Fork of co-ware to make it work with adonis framework
The npm package adonis-co-ware receives a total of 2 weekly downloads. As such, adonis-co-ware popularity was classified as not popular.
We found that adonis-co-ware demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.