2025-05-16 18:09:14 +03:00
|
|
|
import 'package:cherrypick/cherrypick.dart';
|
2025-07-29 17:16:22 +03:00
|
|
|
import 'package:flutter/foundation.dart';
|
2025-05-16 17:56:57 +03:00
|
|
|
import 'package:flutter/material.dart';
|
2025-05-23 12:21:23 +03:00
|
|
|
import 'package:postly/app.dart';
|
2025-05-16 18:09:14 +03:00
|
|
|
import 'di/app_module.dart';
|
2025-05-16 17:56:57 +03:00
|
|
|
|
|
|
|
|
void main() {
|
2025-07-29 17:16:22 +03:00
|
|
|
// Включаем cycle-detection только в debug/test
|
|
|
|
|
if (kDebugMode) {
|
2025-08-08 08:21:19 +03:00
|
|
|
CherryPick.setGlobalLogger(PrintLogger());
|
2025-07-29 17:16:22 +03:00
|
|
|
CherryPick.enableGlobalCycleDetection();
|
|
|
|
|
CherryPick.enableGlobalCrossScopeCycleDetection();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Используем safe root scope для гарантии защиты
|
2025-05-23 14:08:08 +03:00
|
|
|
CherryPick.openRootScope().installModules([$AppModule()]);
|
|
|
|
|
runApp(MyApp());
|
2025-05-16 17:56:57 +03:00
|
|
|
}
|