You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
746 B

4 months ago
import 'package:flutter/material.dart';
4 months ago
import 'package:supplier_new/common/splash_screen.dart';
4 months ago
4 months ago
void main() async {
WidgetsFlutterBinding.ensureInitialized();
runApp(MyApp());
4 months ago
}
4 months ago
// Create a global navigator key
final GlobalKey<NavigatorState> navigatorKey = GlobalKey<NavigatorState>();
4 months ago
4 months ago
class MyApp extends StatelessWidget {
4 months ago
@override
Widget build(BuildContext context) {
return MaterialApp(
4 months ago
debugShowCheckedModeBanner: false,
title: 'Water Management App',
navigatorKey: navigatorKey, // Set the navigator key
4 months ago
theme: ThemeData(
colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
useMaterial3: true,
),
4 months ago
home: SplashScreen(), // Your initial screen
4 months ago
);
}
}