import 'dart:io' show Platform; import 'package:flutter/foundation.dart'; import 'package:go_router/go_router.dart'; import 'package:quotegen_client/pages/home/page.dart'; import 'package:shadcn_flutter/shadcn_flutter.dart'; import 'package:google_mobile_ads/google_mobile_ads.dart'; void main() async { WidgetsFlutterBinding.ensureInitialized(); // Initialize mobile ads (AdMob) only on mobile platforms (not web or macOS) if (!kIsWeb && !Platform.isMacOS) { await MobileAds.instance.initialize(); } runApp(const MyApp()); } class MyApp extends StatelessWidget { const MyApp({super.key}); // This widget is the root of your application. @override Widget build(BuildContext context) { return ShadcnApp.router( title: 'Flutter Demo', routerConfig: _router, scaling: defaultTargetPlatform == TargetPlatform.android ? AdaptiveScaling.only( sizeScaling: 1, textScaling: 1.1, radiusScaling: 1.1 ) : null, theme: ThemeData( colorScheme: ColorSchemes.darkBlue, ), ); } } GoRouter _router = GoRouter( initialLocation: "/", routes: [ HomePage.route ], );