Security News
RubyGems.org Adds New Maintainer Role
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
[![Build Status](https://travis-ci.org/cshum/anchorjs.svg?branch=master)](https://travis-ci.org/cshum/anchorjs)
AnchorJS is a (express inspired) middleware layer for scaffolding asynchronous JavaScript methods.
Node.js
$ npm install anchorjs
Browser
Include the Anchor.js browser build in your pages.
<script src="anchor.js" type="text/javascript"></script>
This will provide anchor
as a global object, or define
it if you are using AMD.
##Example
Middleware
var anchor = require('anchorjs');
function Clock(){
this._tick = 'tick';
this._tock = 'tock';
}
anchor(Clock.prototype)
.use(function(ctx, next){
ctx.logs = ['clock',this._tick];
next();
})
.use('tock',function(ctx, next){
ctx.logs.push(this._tock);
next();
})
.define(['tick','tock'],function(ctx, done){
ctx.logs.push('done');
done(null, ctx.logs);
});
var clock1 = new Clock();
var clock2 = new Clock();
//middleware on prototypal instance
clock2.use('tick',function(ctx, next){
ctx.logs.push('tick2');
next();
});
clock2.use('tock',function(ctx, next){
next('booooom'); //error
});
//Results
clock1.tick(console.log.bind(console)); //null [ 'clock', 'tick', 'done' ]
clock1.tock(console.log.bind(console)); //null ['clock','tick','tock','done']
clock2.tick(console.log.bind(console)); //null ['clock','tick','tick2','done']
clock2.tock(console.log.bind(console)); //'booooom'
0.2.4
0.2.3
0.2.2
0.2.1
0.2.0
0.1.2
MIT
FAQs
[![Build Status](https://travis-ci.org/cshum/anchorjs.svg?branch=master)](https://travis-ci.org/cshum/anchorjs)
We found that anchorjs 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
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.