1
0
Fork 0
mirror of https://github.com/zigzap/zap.git synced 2025-10-20 15:14:08 +00:00

zig-ception update

This commit is contained in:
Rene Schallner 2023-05-19 03:23:28 +02:00
parent fe4e3f94a5
commit bb587ac2a2

View file

@ -61,6 +61,11 @@ when the order of your chain of components isn't perfect yet. 😉
Have a look at an excerpt of the example:
```zig
// create a combined context struct
const Context = zap.Middleware.MixContexts(.{
.{ .name = "?user", .type = UserMiddleWare.User },
.{ .name = "?session", .type = SessionMiddleWare.Session },
});
// we create a Handler type based on our Context
const Handler = zap.Middleware.Handler(Context);