stateful widget syntax code example
Example: creating a stateful widget
class MyApp extends StatefulWidget {
State<StatefulWidget> createState() {
return _MyAppState();
}
}
class _MyAppState extends State<MyApp> {
Widget build(BuildContext context) {
return Container(color: const Color(0xFFFFE306));
}
}