去除Flutter的debug标志

1
2
3
4
5
6
7
8
9
10
Widget build(BuildContext context) {
return MaterialApp(
debugShowCheckedModeBanner: false,
title: 'Flutter Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: MyHomePage(title: 'Flutter Demo Home Page'),
);
}

主要就是这句话

1
debugShowCheckedModeBanner: false,

显示的话改成true或者直接删掉

1
debugShowCheckedModeBanner: true,