@zunh/onion
v0.1.1-beta.2
Published
onion
Readme
@zunh/onion
A simple middleware onion model.
Usage
npm install @zunh/onion
pnpm install @zunh/onion
yarn add @zunh/onionimport Onion from '@zunh/onion';
const onion = new Onion();
onion.use(async (ctx, next) => {
console.log('1');
await next();
console.log('2');
});
onion.use(async (ctx, next) => {
console.log('3');
await next();
console.log('4');
});
onion.run();License
MIT License © 2023-PRESENT zhaozunhong
