@callmeumm/middleware
v0.0.0-typofix
Published
Simple middleware made on node.js
Downloads
1
Readme
@callmeumm/middleware
Simple middleware made on node.js
| 📖 See Docs Here | |-------------------------------------|
Features
- Working with async/await
- Zero dependencies
- Native Promise
Usage
const { Composer } = require("@callmeumm/middleware");
const composer = new Composer({
name: "",
status: ""
});
composer.compose(
(ctx) => {
ctx.data.name = "Pak Asep";
ctx.next();
},
(ctx) => {
ctx.data.status = "Single Ting ting";
ctx.next();
},
(ctx) => {
console.log(ctx.data);
}
).run();