Use logging library
This commit is contained in:
@@ -1,8 +1,17 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:logging/logging.dart';
|
||||
|
||||
import 'login_page.dart';
|
||||
|
||||
void main() {
|
||||
Logger.root.level = Level.ALL; // defaults to Level.INFO
|
||||
Logger.root.onRecord.listen((record) {
|
||||
debugPrint('${record.level.name}: ${record.time}: ${record.message}');
|
||||
if (record.error != null) {
|
||||
debugPrint('${record.error}');
|
||||
}
|
||||
});
|
||||
|
||||
runApp(const MyApp());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user