Use super parameters in templates (#101157)
This commit is contained in:
committed by
GitHub
parent
cc4cc699f8
commit
329ceaef66
@@ -10,7 +10,7 @@ void main() => runApp(const MyApp());
|
||||
|
||||
{{^withPlatformChannelPluginHook}}
|
||||
class MyApp extends StatelessWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
// This widget is the root of your application.
|
||||
@override
|
||||
@@ -34,7 +34,7 @@ class MyApp extends StatelessWidget {
|
||||
}
|
||||
|
||||
class MyHomePage extends StatefulWidget {
|
||||
const MyHomePage({Key? key, required this.title}) : super(key: key);
|
||||
const MyHomePage({super.key, required this.title});
|
||||
|
||||
// This widget is the home page of your application. It is stateful, meaning
|
||||
// that it has a State object (defined below) that contains fields that affect
|
||||
@@ -120,7 +120,7 @@ class _MyHomePageState extends State<MyHomePage> {
|
||||
{{/withPlatformChannelPluginHook}}
|
||||
{{#withPlatformChannelPluginHook}}
|
||||
class MyApp extends StatefulWidget {
|
||||
const MyApp({Key? key}) : super(key: key);
|
||||
const MyApp({super.key});
|
||||
|
||||
@override
|
||||
State<MyApp> createState() => _MyAppState();
|
||||
|
||||
Reference in New Issue
Block a user