2 ways to remove debug banner in flutter
By default, when using Flutter, a conspicuous debug banner is displayed in the Android emulator or iOS simulator. This banner, labeled as DEBUG, is typically located in the upper right corner of the screen. We can remove this banner by 2 methods.
Method 1:
To eliminate the banner, you have the option to employ the debugShowCheckedModeBanner attribute within the MaterialApp() widget. By configuring this attribute as false, the banner will no longer be visible.
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return const MaterialApp(
home: HomeScreen(),
debugShowCheckedModeBanner: false,
);
}
}
Method 2 :
If you are using Android Studio, you can find the option in the Flutter Inspector tab → More Actions.