flutter_logcat 1.3.1 copy "flutter_logcat: ^1.3.1" to clipboard
flutter_logcat: ^1.3.1 copied to clipboard

You can view messages in the console with colors that you define. Also set it to display tags, file paths, and timestamps

flutter_logcat_transparent


Pub Version

In Flutter, logs are displayed in the console without any distinguishing colors.
However, by using this package, you can view messages in the console with colors that you define.
Additionally, you can configure it so that logs are hidden in debug mode, and you can also set it to display tags, file paths, and timestamps.


πŸ“Έ Demo #

In Console

iOS & Others #

image

Android #

image


πŸ“Œ Features #


🌱 Getting Started #

Install Package

flutter_logcat need only three parameters there are message, tag, path, time, history.

  • message : If yon want input message to watch on console.
  • tag: Custom own your's tag name.
  • path: You can watch file preference path. (default: false)
  • time: You can watch current time. (default: false)
  • history: You can call log history all prints.

πŸ’Œ Console Print #

Parameters

parameter required type default output
message βœ”οΈ String [className:lineNumber] message
tag ❌ String (tag) [className:lineNumber] message
path ❌ bool false [className(packageName/className.dart):lineNumber] message
time ❌ bool false 2024-09-25T00:00:000.000000:[className:linenumber] message

πŸš€ Usage #

  • Show only 'message'
    #

    Log.v([String]);
Log.v("message");
Log.i("message");
Log.d("message");
Log.w("message");
Log.e("message");
copied to clipboard

iOS & Others

image

Android

image

  • Show 'message' & 'path' #

    Log.v([String], path: [Boolean])
Log.v("message", path: true);
Log.i("message", path: true);
Log.d("message", path: true);
Log.w("message", path: true);
Log.e("message", path: true);
copied to clipboard

iOS & Others

image

Android

image

  • Show 'message' & 'tag' #

    Log.v([String], tag: [String])
Log.v("message", tag: "FlutterLogcat");
Log.i("message", tag: "FlutterLogcat");
Log.d("message", tag: "FlutterLogcat");
Log.w("message", tag: "FlutterLogcat");
Log.e("message", tag: "FlutterLogcat");
copied to clipboard

iOS & Others

image

Android

image

  • Show 'message' & 'time' #

    Log.v([String], time: [String])
Log.v("message", time: true);
Log.i("message", time: true);
Log.d("message", time: true);
Log.w("message", time: true);
Log.e("message", time: true);
copied to clipboard

iOS & Others

image

Android

image

🧭 Set Log Configure #

It's okay if you don't declare this function.
You only need to use it when an overall setup is required.

  • visible
  • tag
  • time
  • Control VisibleπŸ‘€ to Log.

    Log.configure(visible: [Boolean])
import 'package:flutter/foundation.dart';

Log.configure(visible: kDebugMode);
copied to clipboard
  • If you want setting default tag

    Log.configure(visible: [Boolean], tag: [String])
Log.configure(visible: kDebugMode, tag: "FlutterLogcat");

Log.v(...);
Log.i(...);
...
copied to clipboard

image

  • If you want to see time this

    Log.configure(visible: [Boolean], time: [Boolean])
Log.configure(visible: true, time: true);
copied to clipboard
image

πŸ“Ž Service, Background Functions #

Log.s("message from service");
Log.x("message from background");
copied to clipboard

iOS & Others

image

Android

image

πŸŒ€ Stream Logcat messages #

final subscription = Log.stream.listen(
  (message) => print('message:$message'),   // Save Log Record.
);
copied to clipboard

Stop Stream

Log.stopStream();   // or `dispose()` function.
copied to clipboard

6
likes
160
points
150
downloads
screenshot

Publisher

verified publisherlagerstroemia.net

Weekly Downloads

2024.08.12 - 2025.02.24

You can view messages in the console with colors that you define. Also set it to display tags, file paths, and timestamps

Repository (GitHub)

Documentation

API reference

License

MIT (license)

More

Packages that depend on flutter_logcat