diff --git a/pkgs/shelf_router/example/main.dart b/pkgs/shelf_router/example/main.dart index fb57d61f..275c9805 100644 --- a/pkgs/shelf_router/example/main.dart +++ b/pkgs/shelf_router/example/main.dart @@ -53,7 +53,11 @@ class Service { return Response.notFound('Page not found'); }); - return router.call; + // Set up your Pipeline with any middleware you want to use and set the + // router as the handler. + return const Pipeline() + .addMiddleware(logRequests()) + .addHandler(router.call); } }