Get unlimited public & private packages + team-based management with npm Teams.Learn more »

mali

0.20.0 • Public • Published

Mali

A minimalistic gRPC microservice framework.

npm version build status coverage status JavaScript Style Guide License chat on gitter Donate Buy me a coffee

Installation

Install module and required peer dependencies.

$ npm install mali grpc @grpc/proto-loader

Example

const Mali = require('mali')
 
async function sayHello (ctx) {
  ctx.res = { message: 'Hello '.concat(ctx.req.name) }
}
 
function main () {
  const app = new Mali('helloworld.proto')
  app.use({ sayHello })
  app.start('127.0.0.1:50051')
}

Documentation

Full documentation.

License

Apache-2.0

Install

npm i mali

DownloadsWeekly Downloads

1,895

Version

0.20.0

License

Apache-2.0

Unpacked Size

54 kB

Total Files

11

Homepage

mali.js.org

Last publish

Collaborators

  • avatar