【DoKit生态场景】-描述出现的问题
- Dominant language
- Java
- Stars
- 20.4k
- Forks
- 3.2k
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 2
Description
It is recommended to refer to the following process before submitting issues:https://github.com/didi/DoraemonKit/issues/745
If you still cannot solve your problem, you can submit your issue according to the following template
Please complete the following informations.
> Android、iOS? OS version? Brand?
> Expected behavior and actual behavior.
> Steps to reproduce the problem.
> More informations such as error messages and stack traces are welcomed.
>
建议提issues之前可以参考一下DoKit社区答疑流程:https://github.com/didi/DoraemonKit/issues/745
假如还是无法解决你的问题,你可以按照以下模板来提交你的issue
请补充如下信息。
> Android 还是 iOS?系统版本是多少?手机品牌是什么?(如有)
flutter ios&android
> 期望的表现和实际的表现。(如有)
去除警告
> 问题重现的步骤。(如有)
```
import 'dart:io';
import 'package:aid/pages/login/login_page.dart';
import 'package:aid/pages/splash/splash_page.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'utils/languages.dart';
import 'router/app_pages.dart';
import 'router/app_routes.dart';
import 'package:aid/utils/export_library.dart';
void main() async {
WidgetsFlutterBinding.ensureInitialized(); // Add this
await SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp]);
DoKit.runApp(
app: DoKitApp(MyApp()),
useInRelease: true,
releaseAction: () => {
HttpOverrides.global = MyHttpOverrides(),
},
exceptionCallback: (dynamic obj, StackTrace trace) {
print('ttt$obj');
},
);
}
final GlobalKey navigatorKey = GlobalKey();
class MyApp extends StatelessWidget {
const MyApp({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return ScreenUtilInit(
designSize: const Size(750, 1334),
builder: () => GetMaterialApp(
navigatorKey: navigatorKey,
translations: Languages(), // 你的翻译
locale: const Locale('zh', 'CN'), // 将会按照此处指定的语言翻译
fallbackLocale: const Locale('en', 'US'), // 添加一个回调语言选项,以备上面指定的语言翻译不存在
initialRoute: AppRoutes.SPLASH,
getPages: AppPages.list,
debugShowCheckedModeBanner: false,
themeMode: ThemeMode.system,
),
);
}
}
class MyHttpOverrides extends HttpOverrides {
@override
HttpClient createHttpClient(SecurityContext? context) {
return super.createHttpClient(context)..badCertificateCallback = (X509Certificate cert, String host, int port) => true;
}
}
```
> 其他的错误信息和堆栈信息如果有也可以一并提供出来。(如有)
警告:

Contributor guide
Assessment
This issue has not been assessed yet.