Closed savy-91 closed 2 years ago
add ScreenUtil.setContext(context); in builder
@override
Widget build(BuildContext context) {
return ScreenUtilInit(
designSize: const Size(360, 690),
minTextAdapt: true,
builder: () {
return GetMaterialApp(
builder: (context, widget) {
ScreenUtil.setContext(context);
return MediaQuery(
data: MediaQuery.of(context).copyWith(textScaleFactor: 1.0),
child: widget!);
},
debugShowCheckedModeBanner: false,
theme: settingService.getThemeData(context),
home: SplashPage(),
);
},
);
}
Sorry, it's my negligence
I, like many others, just stumbled upon tests breaking without any reason and
No MediaQuery widget ancestor found
After 4 hours of work lost today, trying to find the culprit of the failed tests in some of our commits, I realized that you do not follow Semantic Versioning.
Here is proof:
This means that whenever you are making breaking changes and releasing a new minor version, you are breaking all the apps that use your dependency with the default constraint version
^5.0.3
for example.Why don't you follow semantic versioning?
Here is something for you to read:
Please start using semantic versioning, you will receive less issues and people will be happier.