Wondering what’s next for npm?Check out our public roadmap! »

seneca-promisified

0.6.13 • Public • Published

Metapackage containing all of the seneca-promisified wrappers.

Example

 
const cbSeneca = require('seneca')();
cbSeneca.use('entity');
const SenecaPromisified = require('seneca-promisified');
const seneca = new SenecaPromisified(cbSeneca);
seneca.add({
  role: 'entity',
  name: 'greet',
  cmd: 'save'
}, (args) => {
  return {
    gretting: 'hello ' + args.ent.name
  };
});
 
seneca.make('greet').save$({ name: 'AGhost-7' }).then((res) => {
  console.log(res.greeting); // => hello AGhost-7
});
 

API Documentation

See: http://aghost-7.github.io/seneca-promisified

Install

npm i seneca-promisified

DownloadsWeekly Downloads

157

Version

0.6.13

License

MIT

Unpacked Size

2.24 kB

Total Files

5

Last publish

Collaborators

  • avatar