Files
cherrypick/examples/postly/lib/main.dart

33 lines
1.1 KiB
Dart
Raw Normal View History

2025-05-16 18:09:14 +03:00
import 'package:cherrypick/cherrypick.dart';
import 'package:flutter/foundation.dart';
2025-05-16 17:56:57 +03:00
import 'package:flutter/material.dart';
import 'package:flutter_bloc/flutter_bloc.dart';
2025-05-23 12:21:23 +03:00
import 'package:postly/app.dart';
import 'package:postly/di/core_module.dart';
import 'package:talker_bloc_logger/talker_bloc_logger_observer.dart';
import 'package:talker_flutter/talker_flutter.dart';
2025-05-16 18:09:14 +03:00
import 'di/app_module.dart';
import 'package:talker_cherrypick_logger/talker_cherrypick_logger.dart';
2025-05-16 17:56:57 +03:00
void main() {
final talker = Talker();
final talkerLogger = TalkerCherryPickObserver(talker);
Bloc.observer = TalkerBlocObserver(talker: talker);
CherryPick.setGlobalObserver(talkerLogger);
// Включаем cycle-detection только в debug/test
if (kDebugMode) {
CherryPick.enableGlobalCycleDetection();
CherryPick.enableGlobalCrossScopeCycleDetection();
}
// Используем safe root scope для гарантии защиты
style: reformat codebase using melos format Applied consistent code formatting across all packages using \$ melos format └> dart format . └> RUNNING (in 8 packages) -------------------------------------------------------------------------------- benchmark_di: Formatted 18 files (0 changed) in 0.30 seconds. benchmark_di: SUCCESS -------------------------------------------------------------------------------- cherrypick: Formatted 24 files (0 changed) in 0.34 seconds. cherrypick: SUCCESS -------------------------------------------------------------------------------- cherrypick_annotations: Formatted 11 files (0 changed) in 0.14 seconds. cherrypick_annotations: SUCCESS -------------------------------------------------------------------------------- cherrypick_flutter: Formatted 3 files (0 changed) in 0.15 seconds. cherrypick_flutter: SUCCESS -------------------------------------------------------------------------------- cherrypick_generator: Formatted 17 files (0 changed) in 0.27 seconds. cherrypick_generator: SUCCESS -------------------------------------------------------------------------------- client_app: Formatted 4 files (0 changed) in 0.14 seconds. client_app: SUCCESS -------------------------------------------------------------------------------- postly: Formatted lib/router/app_router.gr.dart Formatted 23 files (1 changed) in 0.33 seconds. postly: SUCCESS -------------------------------------------------------------------------------- talker_cherrypick_logger: Formatted 4 files (0 changed) in 0.18 seconds. talker_cherrypick_logger: SUCCESS -------------------------------------------------------------------------------- $ melos format └> dart format . └> SUCCESS. No functional or logic changes included.
2025-08-13 15:38:44 +03:00
CherryPick.openRootScope()
.installModules([CoreModule(talker: talker), $AppModule()]);
style: reformat codebase using melos format Applied consistent code formatting across all packages using \$ melos format └> dart format . └> RUNNING (in 8 packages) -------------------------------------------------------------------------------- benchmark_di: Formatted 18 files (0 changed) in 0.30 seconds. benchmark_di: SUCCESS -------------------------------------------------------------------------------- cherrypick: Formatted 24 files (0 changed) in 0.34 seconds. cherrypick: SUCCESS -------------------------------------------------------------------------------- cherrypick_annotations: Formatted 11 files (0 changed) in 0.14 seconds. cherrypick_annotations: SUCCESS -------------------------------------------------------------------------------- cherrypick_flutter: Formatted 3 files (0 changed) in 0.15 seconds. cherrypick_flutter: SUCCESS -------------------------------------------------------------------------------- cherrypick_generator: Formatted 17 files (0 changed) in 0.27 seconds. cherrypick_generator: SUCCESS -------------------------------------------------------------------------------- client_app: Formatted 4 files (0 changed) in 0.14 seconds. client_app: SUCCESS -------------------------------------------------------------------------------- postly: Formatted lib/router/app_router.gr.dart Formatted 23 files (1 changed) in 0.33 seconds. postly: SUCCESS -------------------------------------------------------------------------------- talker_cherrypick_logger: Formatted 4 files (0 changed) in 0.18 seconds. talker_cherrypick_logger: SUCCESS -------------------------------------------------------------------------------- $ melos format └> dart format . └> SUCCESS. No functional or logic changes included.
2025-08-13 15:38:44 +03:00
runApp(MyApp(
talker: talker,
));
2025-05-16 17:56:57 +03:00
}