1.1.2 • Published 5 years ago

msnote v1.1.2

Weekly downloads
1
License
ISC
Repository
github
Last release
5 years ago

note

用于node.js的富有表现力的HTTP2中间件框架,使Web应用程序和API更易于编写。
Note的中间件堆栈以类似堆栈的方式流动,允许您执行下游操作,然后过滤和操作上游响应。

note 与 koa

note 根据 koa API进行开发 查阅了 Koa 的源码

note与Koa的不同

note完全采用http2进行开发 只支持node10以上版本

note 的请求处理和koa有所不同 note基于 http2 stream

Hello World

import Note from 'note';
const app = new Note({
  key: fs.readFileSync('localhost-privkey.pem'),
  cert: fs.readFileSync('localhost-cert.pem')
});

app.use(async (ctx) => {
  ctx.body = 'Hello Koa';
});

app.listen(3000);
1.1.2

5 years ago

1.1.1

5 years ago

1.1.0

5 years ago

1.0.0

5 years ago