ansi_logger

Creator: coderz1093

Last updated:

0 purchases

ansi_logger Image
ansi_logger Images

Languages

Categories

Add to Cart

Description:

ansi logger

ansi_logger #
Pretty logger with ansi colors
How to use #
see the example
Screenshots #












Working with dio #

first create Interceptor and override onRequest and onError method


class _Interceptor extends Interceptor {
@override
void onError(DioError err, ErrorInterceptorHandler handler) {
super.onError(err, handler);
// See the example to know how to log this Error
}
@override
void onResponse(Response response, ResponseInterceptorHandler handler) {
super.onResponse(response, handler);
// See the example to know how to log this response
}
}

copied to clipboard

then you should use this Interceptor

Dio dio = Dio();
dio.interceptors.add(_Interceptor());
dio.get("https://jsonplaceholder.typicode.com/todos/1");

copied to clipboard

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.