Co-authored-by: MENDOZA BALLARDO GAEL RICARDO <gael-meb123@users.noreply.github.com>
Co-authored-by: Azareth-Tr <Azareth-Tr@users.noreply.github.com> Co-authored-by: eddgranados12 <eddgranados12@users.noreply.github.com> vistas de mockup actualizaco
This commit is contained in:
25
views_v2/main.dart
Normal file
25
views_v2/main.dart
Normal file
@@ -0,0 +1,25 @@
|
||||
// lib/main.dart
|
||||
// Punto de entrada. Inicializa Firebase, FCM, y monta el árbol Riverpod.
|
||||
|
||||
import 'package:firebase_core/firebase_core.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||
import 'features/notifications/notification_service.dart';
|
||||
import 'app.dart';
|
||||
|
||||
void main() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
|
||||
// Inicializar Firebase (requiere google-services.json en android/app/)
|
||||
await Firebase.initializeApp();
|
||||
|
||||
// Inicializar FCM: permisos, canal Android, handlers foreground/background
|
||||
await NotificationService.initialize();
|
||||
|
||||
runApp(
|
||||
// ProviderScope es el contenedor global de Riverpod
|
||||
const ProviderScope(
|
||||
child: RecolectaApp(),
|
||||
),
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user