38 lines
1.2 KiB
Dart
38 lines
1.2 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:learn_project/screens/home.dart';
|
|
import 'package:supabase_flutter/supabase_flutter.dart';
|
|
|
|
Future<void> main() async {
|
|
WidgetsFlutterBinding.ensureInitialized();
|
|
|
|
await Supabase.initialize(
|
|
url: 'http://192.168.179.86:8000/',
|
|
anonKey: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InZ2dGVmcWRxYWhjcHpnb2x2dXB2Iiwicm9sZSI6ImFub24iLCJpYXQiOjE3MTYwMjE2NTIsImV4cCI6MjAzMTU5NzY1Mn0.1bp5V61Oguo5zLUhCFJmCabUY1sujeISr_CR2XUKvh4',
|
|
);
|
|
runApp(const MyApp());
|
|
}
|
|
|
|
|
|
/// Supabase client
|
|
final supabase = Supabase.instance.client;
|
|
/// Error message to display the user when unexpected error occurs.
|
|
const unexpectedErrorMessage = 'Unexpected error occurred.';
|
|
class MyApp extends StatelessWidget {
|
|
const MyApp({super.key});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return MaterialApp(
|
|
debugShowCheckedModeBanner: false,
|
|
//title: 'Recipes',
|
|
theme: ThemeData(
|
|
colorScheme: ColorScheme.fromSwatch().copyWith(
|
|
primary: Colors.white,
|
|
secondary: const Color(0xff8DB646), // Your accent color
|
|
),
|
|
),
|
|
home: const HomePage(),
|
|
);
|
|
}
|
|
}
|