Skip to content
pubscout

pretty_dio_logger

1.4.0, released 2 years ago by codeness.ly

A Dio interceptor that logs network calls in a pretty, easy to read format.

WASM-ready
$ flutter pub add pretty_dio_logger
Source repository

What it does

Pretty Dio logger intercepts network requests, responses, and errors made via the Dio client and formats them neatly for the console. It supports customization options like toggling headers, bodies, compactness, and filtering specific requests.

AI-written summary of version 1.4.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You are using the Dio package for network requests
  • You want readable, formatted console logs for your API requests and responses
  • You need to filter out specific network logs or control log output dynamically

Skip it when

  • You are not using Dio for networking
  • You require advanced production-grade error reporting dashboards rather than console logs

Strengths

  • Easy setup as a standard Dio interceptor
  • Customizable formatting with options for headers, bodies, and max width
  • Includes filtering capabilities to ignore specific paths or data types

Weaknesses

  • Limited to console output and formatting
  • Does not provide remote crash reporting or persistent network log storage

Setup

Kind
Pure Dart
Effort
Low
Code generation
No
Direct dependencies
1

Simply add PrettyDioLogger to your Dio interceptors list.

Dio dio = Dio();
dio.interceptors.add(PrettyDioLogger());

Alternatives

Packages that do the same job and could replace pretty_dio_logger.

  • talker

    Provides advanced and extensible logging and error handling for Flutter applications, including network logs.

Works with

Packages commonly used together with pretty_dio_logger: ones it builds on, ones built on it, and its own family.