diff --git a/example/lib/main.dart b/example/lib/main.dart index 18c5f62..7bdefdf 100644 --- a/example/lib/main.dart +++ b/example/lib/main.dart @@ -20,10 +20,20 @@ final class ControllerObserver implements IControllerObserver { @override void onHandler(HandlerContext context) { + final stopwatch = Stopwatch()..start(); l.d( 'Controller | ' '${context.controller.name}.${context.name}', context.meta, ); + context.done.whenComplete(() { + stopwatch.stop(); + l.d( + 'Controller | ' + '${context.controller.name}.${context.name} | ' + 'duration: ${stopwatch.elapsed}', + context.meta, + ); + }); } @override