FlutterTest
FlutterTest copied to clipboard
不想main方法中初始化,如何处理?
InnerWidgetsFlutterBinding.ensureInitialized() ..attachRootWidget(new MyApp()) ..scheduleWarmUpFrame();
现在这段代码是在main方法执行,这样项目中所有页面都会受影响,因为我们的工程中已经有很多页面了,我想在新页面中使用此配置,其他页面保持原样,请问有什么好的办法?