Flutter : Android Studio #4 Create New Page

import 'package:flutter/material.dart';

class HomePage extends StatefulWidget {
  const HomePage({Key? key}) : super(key: key);

  @override
  _HomePageState createState() => _HomePageState();
}

class _HomePageState extends State<HomePage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
        appBar: AppBar(
          title: Text('HomePage'),
        )
    );
  }
}
initialRoute: '/',
      routes: {
        '/' : (context) => HomePage()
      },
(Visited 6 times, 1 visits today)
Spread the love
Published
Categorized as Flutter

Leave a comment